|
|
@ -754,6 +754,11 @@ NSString *const Keychain_ImportBackupKey = @"ImportBackupKey";
|
|
|
|
return NO;
|
|
|
|
return NO;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Clear out any existing keys in this instance of NSUserDefaults.
|
|
|
|
|
|
|
|
for (NSString *key in userDefaults.dictionaryRepresentation) {
|
|
|
|
|
|
|
|
[userDefaults removeObjectForKey:key];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// TODO: this doesn't yet remove any keys, so you end up with the "union".
|
|
|
|
// TODO: this doesn't yet remove any keys, so you end up with the "union".
|
|
|
|
for (NSString *key in dictionary) {
|
|
|
|
for (NSString *key in dictionary) {
|
|
|
|
id value = dictionary[key];
|
|
|
|
id value = dictionary[key];
|
|
|
@ -761,6 +766,8 @@ NSString *const Keychain_ImportBackupKey = @"ImportBackupKey";
|
|
|
|
[userDefaults setObject:value forKey:key];
|
|
|
|
[userDefaults setObject:value forKey:key];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[userDefaults synchronize];
|
|
|
|
|
|
|
|
|
|
|
|
return YES;
|
|
|
|
return YES;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|