You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-06-27 23:28:38 +02:00
All: Fixed setting issue that would cause a password to be saved in plain text in the database, even when the keychain is working
This commit is contained in:
@ -1318,6 +1318,11 @@ class Setting extends BaseModel {
|
||||
if (currentValue !== s.value) {
|
||||
const wasSet = await this.keychainService().setPassword(passwordName, s.value);
|
||||
if (wasSet) continue;
|
||||
} else {
|
||||
// The value is already in the keychain - so nothing to do
|
||||
// Make sure to `continue` here otherwise it will save the password
|
||||
// in clear text in the database.
|
||||
continue;
|
||||
}
|
||||
} catch (error) {
|
||||
this.logger().error(`Could not set setting on the keychain. Will be saved to database instead: ${s.key}:`, error);
|
||||
|
Reference in New Issue
Block a user