'CFURLCreateStringByAddingPercentEscapes' is deprecated in iOS 9.0
sneakybVer opened this issue · comments
Stephen Betts commented
'CFURLCreateStringByAddingPercentEscapes' is deprecated: first deprecated in iOS 9.0 - Use [NSString stringByAddingPercentEncodingWithAllowedCharacters:] instead, which always uses the recommended UTF-8 encoding, and which encodes for a specific URL component or subcomponent (since each URL component or subcomponent has different rules for what characters are valid).
Shihao Xia commented
I fixed that
#define TDPCEN(s)
([[s description] stringByAddingPercentEncodingWithAllowedCharacters:[[NSCharacterSet characterSetWithCharactersInString:@"!*'();:@&=+$,/?%#[] "] invertedSet]]) @sneakybVer
Max Howell commented
Merged.