mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-09-20 04:44:43 -04:00
Clear LastDatabases and LastKeyFiles when they are disabled in settings
This commit is contained in:
parent
649a14db84
commit
2e4f1a21b4
1 changed files with 9 additions and 0 deletions
|
@ -225,6 +225,15 @@ void SettingsWidget::saveSettings()
|
|||
config()->set("security/passwordscleartext", m_secUi->passwordCleartextCheckBox->isChecked());
|
||||
config()->set("security/passwordsrepeat", m_secUi->passwordRepeatCheckBox->isChecked());
|
||||
|
||||
// Security: clear storage if related settings are disabled
|
||||
if (!config()->get("RememberLastDatabases").toBool()) {
|
||||
config()->set("LastDatabases", QVariant());
|
||||
}
|
||||
|
||||
if (!config()->get("RememberLastKeyFiles").toBool()) {
|
||||
config()->set("LastKeyFiles", QVariant());
|
||||
}
|
||||
|
||||
for (const ExtraPage& page: asConst(m_extraPages)) {
|
||||
page.saveSettings();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue