mirror of
https://github.com/streetwriters/notesnook.git
synced 2026-07-10 04:21:21 +02:00
core: clear key cache & fix private key encoding in saveInboxKeys() (#9851)
* after saving new keys, we didn't clear the cache so getInboxKeys() was still returning old keys * remove unnecessary JSON.stringify on private key in saveInboxKeys() Signed-off-by: 01zulfi <85733202+01zulfi@users.noreply.github.com>
This commit is contained in:
@@ -538,10 +538,11 @@ class UserManager {
|
||||
public: keys.publicKey,
|
||||
private: await this.db
|
||||
.storage()
|
||||
.encrypt(userEncryptionKey, JSON.stringify(keys.privateKey))
|
||||
.encrypt(userEncryptionKey, keys.privateKey)
|
||||
}
|
||||
};
|
||||
await this.updateUser(updatePayload);
|
||||
this.keyManager.clearCache();
|
||||
}
|
||||
|
||||
async sendVerificationEmail(newEmail?: string) {
|
||||
|
||||
Reference in New Issue
Block a user