GET方法Alamofire我有一些問題。當我的數據我有錯誤:Alamofire扁平錯誤:意外地發現零,而解包一個可選值
EXC_BAD_INSTRUCTION(代碼= EXC_I386_INVOP,子碼=爲0x0) 致命錯誤:意外發現零而展開的可選值
我在做什麼錯?我的代碼:
let URLString = "http://MyURLWebService...";
Alamofire.request(.GET, URLString)
.responseJSON { (response) in
print(response.request) // original URL request
print(response.response) // URL response
print(response.data) // server data
print(response.result) // result of response serialization
if let JSON = response.result.value {
print(JSON["Phones"] as! String)
//print("JSON: \(JSON)")
}
}
我的格式REST API數據: [{電話 「:」 + 1(100)111-22-33「,」Phones2「:null}] – Dim