问:GMSPlaceField 结果为无效实例



我注意到,如果我在我的请求中添加另一个 GMSPlaceField 字段,如下所示:https://developers.google.com/places/ios-sdk/client-migration#fetch_a_place_photo

并说使字段如下所示:

let fields: GMSPlaceField = GMSPlaceField(rawValue: UInt(GMSPlaceField.name.rawValue) | UInt(GMSPlaceField.photos.rawValue))!

字段结果为 GMSPlaceField 的无效实例:

GMSPlaceField   <invalid>

因此请求失败

事实证明,GMSPlaceField返回了正确的字段,Xcode调试器说无效,但它是有效的。

相关内容

最新更新