fix: wrong error message on incorrect password

Adjust to the new error messages when opening the database with the DB
pool

Fixes #10830
This commit is contained in:
Lukáš Tinkl 2023-05-29 11:19:52 +02:00 committed by Lukáš Tinkl
parent 1f582451aa
commit 266b2406cc
1 changed files with 1 additions and 1 deletions

View File

@ -138,7 +138,7 @@ Item {
if (error) {
if (!root.startupStore.selectedLoginAccount.keycardCreatedAccount) {
// SQLITE_NOTADB: "file is not a database"
if (error === "file is not a database") {
if (error === "file is not a database" || error.startsWith("failed to set ")) {
txtPassword.validationError = qsTr("Password incorrect")
} else {
txtPassword.validationError = qsTr("Login failed: %1").arg(error.toUpperCase())