Almofire 拼接get请求url包含中文报错

217 阅读1分钟

解决办法

let newUrl =  url.addingPercentEncoding(withAllowedCharacters: CharacterSet.urlQueryAllowed)