fix: addresses not being able to unset a keyfile once added to a vault

Refs: #2073 #1924 #2038 #1941
This commit is contained in:
Aetherinox 2024-04-05 13:43:02 -07:00
parent fcdce278a7
commit 738d9c6a00
No known key found for this signature in database
GPG Key ID: CB5C4C30CD0D4028
1 changed files with 1 additions and 1 deletions

View File

@ -536,7 +536,7 @@ class FileModel extends Model {
}
removeKeyFile() {
this.db.credentials.keyFileHash = null;
this.db.credentials.setKeyFile(null);
const changed = !!this.oldKeyFileHash;
if (!changed && this.db.credentials.passwordHash === this.oldPasswordHash) {
this.db.meta.keyChanged = this.oldKeyChangeDate;