We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
how i can set acceptableContentTypes .when the response data is not json?
error info: Error Domain=com.alamofire.error.serialization.response Code=-1016 "Request failed: unacceptable content-type: text/html" UserInfo={NSLocalizedDescription=Request failed: unacceptable content-type: text/html, NSErrorFailingURLKey=
The text was updated successfully, but these errors were encountered:
i use my way to deal with this problem. open the file XMEngine.m.In line 495 ,cancel this annotation .
XMEngine.m
_afJSONResponseSerializer.acceptableContentTypes = [NSSet setWithObjects:@"application/json", @"text/json", @"text/javascript", @"text/html", @"text/plain", nil];
it's a stupid way to deal.looking forward to the author to deal with it.thx
Sorry, something went wrong.
[[XMEngine sharedEngine].sessionManager.requestSerializer setValue:@"whatyouwanttomodify" forHttpHeaderField:@"Content-Type"];
No branches or pull requests
how i can set acceptableContentTypes .when the response data is not json?
The text was updated successfully, but these errors were encountered: