iOS10 应用已崩溃,因为它试图访问隐私敏感数据

iOS10 app has crashed because it attempted to access privacy-sensitive data

当我尝试打开摄像机时,我的应用程序崩溃了。它打开相机时很好,但是当我从图像切换到视频时出现此错误:

[access] This app has crashed because it attempted to access privacy-sensitive data without a usage description.  The app's Info.plist must contain an NSMicrophoneUsageDescription key with a string value explaining to the user how the app uses this data.

我觉得这很奇怪,因为我在我的 plist 文件中添加了权限。

<key>NSCameraUsageDescription</key>
<string>Camera is used to make pictures when creating a job</string>

在您的 .plist 中添加此键:Privacy - Microphone Usage Description 和您想要的值。