6:关于iOS11定位失效的问题解决方案
This app has attempted to access privacy-sensitive data without a usage description. The app’s Info.plist must contain both NSLocationAlwaysAndWhenInUseUsageDescription and NSLocationWhenInUseUsageDescription keys with string values explaining to the user how the app uses this data
具体原因是苹果原来的永久定位权限已经下降为使用期间
需要新增如下两个权限,
NSLocationAlwaysAndWhenInUseUsageDescription 和 NSLocationWhenInUseUsageDescription
在plist文件中添加这两个就可以了。
<key>NSLocationAlwaysAndWhenInUseUsageDescription</key>
<string>允许访问位置</string>

本文解决了iOS11中应用尝试访问敏感数据但未提供使用描述的问题。更新了Info.plist文件,增加了NSLocationAlwaysAndWhenInUseUsageDescription及NSLocationWhenInUseUsageDescription两个键值,以满足苹果对定位权限的新要求。
4450

被折叠的 条评论
为什么被折叠?



