CKContainer accountStatusWithCompletionHandler返回错误的值 [英] CKContainer accountStatusWithCompletionHandler returns wrong value
问题描述
accountStatusWithCompletionHandler
方法返回 .NoAccount
值。知道为什么返回的值不是 .Available
吗?我已登录到iCloud,并已连接到Internet。
accountStatusWithCompletionHandler
method returns .NoAccount
value. Any idea why returned value is not .Available
? I am logged in to iCloud, and connecting to internet.
文档说 .NoAccount
表示:
该用户的iCloud帐户不可用,因为尚未为此设备提供任何帐户
信息。
The user’s iCloud account is not available because no account information has been provided for this device.
我没有收到任何错误。原因可能是该应用未使用私有数据库? Doc说:
I do not receive any error. The reason may be that app is not using private database? Doc says:
在访问私有数据库以确定
该数据库是否可用之前调用此方法。
Call this method before accessing the private database to determine whether that database is available.
推荐答案
弄清楚,该应用程序的iCloud Drive已关闭。
Figured out, iCloud Drive was turned off for the app.
这篇关于CKContainer accountStatusWithCompletionHandler返回错误的值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!