CloudKit クエリで非常に一般的なエラーが発生します。修正方法がわかりません。誰か提案はありますか?
エラーは<CKError 0x17065c230: "Internal Error" (1/2005)>
Error occurred. Error = <CKError 0x174648370: "Internal Error" (1/2005)>
私のコードは次のとおりです。
override func viewDidLoad() {
super.viewDidLoad()
let database = CKContainer.defaultContainer().publicCloudDatabase
let container = CKContainer.defaultContainer()
let publicDB = container.publicCloudDatabase
let data = CKRecord(recordType: "theUsers")
var predicate = NSPredicate(value: true)
let myQuery = CKQuery(recordType: "theUsers", predicate: predicate)
var mySelfie = matchedSelfie
publicDB.performQuery(myQuery, inZoneWithID: nil) {
results, error in
if error != nil {
println(error)
} else {
for record in results{
if let aselfie = record.stringForKey("selfie") { //Optional binding
mySelfie.append(aselfie) //Append to string array
mySelfie.append(aselfie)
return ()
}
}}}
}