Browse Source

Merge branch 'master' of http://git.shengws.com/csx/gdyb

csx 3 years ago
parent
commit
841700cac9
1 changed files with 4 additions and 4 deletions
  1. 4 4
      utils/csbhttp/httpcaller.go

+ 4 - 4
utils/csbhttp/httpcaller.go View File

@@ -215,10 +215,10 @@ func Invoke(params HttpParams) (str string, rtnHeaders map[string][]string, hcEr
215 215
 
216 216
 	defaultContentType := "application/x-www-form-urlencoded"
217 217
 	if params.ct.jsonBody != "" {
218
-		_, err = json.Marshal(params.ct.jsonBody)
219
-		if err == nil {
220
-			return str, rtnHeaders, &HttpCallerException{Message: "failed to bad content type json string", CauseErr: err}
221
-		}
218
+		json.Marshal(params.ct.jsonBody)
219
+		//if err == nil {
220
+		//	return str, rtnHeaders, &HttpCallerException{Message: "failed to bad content type json string", CauseErr: err}
221
+		//}
222 222
 		reqStr = params.ct.jsonBody
223 223
 		defaultContentType = params.ct.contentType
224 224
 		reqUrl = appendParams(reqUrl, data.Encode())