[Issue #521] Fixing AFContentTypesFromHTTPHeader to correctly handle comma-delimited content types
This commit is contained in:
parent
501c4f18d4
commit
94bbe4c1e8
1 changed files with 2 additions and 0 deletions
|
|
@ -49,6 +49,8 @@ NSSet * AFContentTypesFromHTTPHeader(NSString *string) {
|
|||
NSString *contentType = nil;
|
||||
if ([scanner scanUpToString:@";" intoString:&contentType]) {
|
||||
[scanner scanUpToString:@"," intoString:nil];
|
||||
} else {
|
||||
[scanner scanUpToCharactersFromSet:_skippedCharacterSet intoString:&contentType];
|
||||
}
|
||||
|
||||
if (contentType) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue