【发布时间】:2016-11-17 00:44:27
【问题描述】:
我的 json 有餐厅的 googleplus 链接,如果餐厅没有任何 googleplus 链接,它会显示 null 但我收到上述错误。
if dict["googlepluslink"] != nil
{
self.googlepluslink.append((dict["googlepluslink"] as? String)!)
}
else
{
self.googlepluslink.append(("-" as? String)!)
}
无法将“NSNull”(0x10aa1b600)类型的值转换为“NSString”(0x10b4dab48)
【问题讨论】: