尝试访问联系人时,应用会与__CRASHING_DUE_TO_PRIVACY_VIOLATION__崩溃 [英] App crashes with __CRASHING_DUE_TO_PRIVACY_VIOLATION__ when trying to access contacts

查看:913
本文介绍了尝试访问联系人时,应用会与__CRASHING_DUE_TO_PRIVACY_VIOLATION__崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

更新到iOS 10时,当尝试通过插件 cordova-plugin-contacts v2访问联系人时。 2.0,应用程式会退出

Upon updating to iOS 10, when trying to access the contacts through plugin cordova-plugin-contacts v2.2.0, the app exits with

__ CRASHING_DUE_TO_PRIVACY_VIOLATION __

我不知道现在可以提供什么其他额外的信息,只是让我知道,如果我可以更具体。 Thanx。

I don't know what other extra info i can provide right now, just let me know if i can be more specific. Thanx.

也许这是一些用途: http:// stackoverflow。 com / a / 39416858/592641 ,但我找不到如何在cordova中指定这些使用描述的指南。

Maybe this is of some use: http://stackoverflow.com/a/39416858/592641, but i couldn't find a guide of how to specify those usage descriptions in cordova.

推荐答案

简而言之, * info.plist

正在使用Cordova,我发现将它们放在config.xml中的最简单的方法是:

Since we are using Cordova, the simplest way I found to put them inside config.xml is this:


  1. 安装 cordova-custom-config

  2. 在config.xml中添加以下内容:

<platform name="ios">
    <config-file parent="NSContactsUsageDescription" target="*info.plist">
      <string>Easily invite your friends</string>
    </config-file>
</platform>

这篇关于尝试访问联系人时,应用会与__CRASHING_DUE_TO_PRIVACY_VIOLATION__崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆