Fix erase and removePGPKeys
- Remove SharedDefaults instead of Defaults
This commit is contained in:
parent
d2ba620ae4
commit
86a6fb6395
1 changed files with 6 additions and 6 deletions
|
|
@ -726,7 +726,7 @@ public class PasswordStore {
|
||||||
|
|
||||||
deleteCoreData(entityName: "PasswordEntity")
|
deleteCoreData(entityName: "PasswordEntity")
|
||||||
|
|
||||||
Defaults.removeAll()
|
SharedDefaults.removeAll()
|
||||||
storeRepository = nil
|
storeRepository = nil
|
||||||
|
|
||||||
NotificationCenter.default.post(name: .passwordStoreUpdated, object: nil)
|
NotificationCenter.default.post(name: .passwordStoreUpdated, object: nil)
|
||||||
|
|
@ -818,11 +818,11 @@ public class PasswordStore {
|
||||||
public func removePGPKeys() {
|
public func removePGPKeys() {
|
||||||
Utils.removeFileIfExists(atPath: Globals.pgpPublicKeyPath)
|
Utils.removeFileIfExists(atPath: Globals.pgpPublicKeyPath)
|
||||||
Utils.removeFileIfExists(atPath: Globals.pgpPrivateKeyPath)
|
Utils.removeFileIfExists(atPath: Globals.pgpPrivateKeyPath)
|
||||||
Defaults.remove(.pgpKeySource)
|
SharedDefaults.remove(.pgpKeySource)
|
||||||
Defaults.remove(.pgpPublicKeyArmor)
|
SharedDefaults.remove(.pgpPublicKeyArmor)
|
||||||
Defaults.remove(.pgpPrivateKeyArmor)
|
SharedDefaults.remove(.pgpPrivateKeyArmor)
|
||||||
Defaults.remove(.pgpPrivateKeyURL)
|
SharedDefaults.remove(.pgpPrivateKeyURL)
|
||||||
Defaults.remove(.pgpPublicKeyURL)
|
SharedDefaults.remove(.pgpPublicKeyURL)
|
||||||
Utils.removeKeychain(name: ".pgpKeyPassphrase")
|
Utils.removeKeychain(name: ".pgpKeyPassphrase")
|
||||||
pgp = ObjectivePGP()
|
pgp = ObjectivePGP()
|
||||||
publicKey = nil
|
publicKey = nil
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue