mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-12 02:21:29 +08:00
Merge pull request #78 from lihuacai168/hot-fix
fix: custom content-type prior to default
This commit is contained in:
@@ -678,7 +678,9 @@ func (r *caseRunner) runStepRequest(step *TStep) (stepResult *stepData, err erro
|
||||
if err != nil {
|
||||
return stepResult, err
|
||||
}
|
||||
req.Header.Set("Content-Type", "application/json; charset=UTF-8")
|
||||
if req.Header.Get("Content-Type") == "" {
|
||||
req.Header.Set("Content-Type", "application/json; charset=utf-8")
|
||||
}
|
||||
}
|
||||
case string:
|
||||
dataBytes = []byte(vv)
|
||||
|
||||
Reference in New Issue
Block a user