alamofire.error Code=-6006 "JSON could not be serialized

前端 未结 3 1454
名媛妹妹
名媛妹妹 2020-12-03 17:42

Been working on this for a bit with no success. I have a function that goes to a UIButton solely to perform alamofire calls to my rails api which uses all JSON.

3条回答
  •  無奈伤痛
    2020-12-03 17:50

    You need to check the mimeType it will be "text/plain" instead of "application/json". That's why JSONSerialization class not able to parse the data.

提交回复
热议问题