let send: String = String(format:"http://abc.xyz/%@",userName)
print(send)
let url=URL(string:send)
do
{
let userData = try Data(contentsOf: url!)
let loginResponse = try JSONSerialization.jsonObject(with: userData, options: JSONSerialization.ReadingOptions.allowFragments) as! [string:Anyobject]
print(loginResponse)
let arr=(loginResponse["Activities"])
if (![loginResponse["Activities"]]=NSNull)
{
print(arr!)
}
如果响应不为null,那么我需要将一些对象添加到数组