Skip to content

Commit

Permalink
More accurately log what happens when deleteAppPassword is complete i…
Browse files Browse the repository at this point in the history
…n Account

Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
  • Loading branch information
claucambra committed Feb 13, 2023
1 parent a666b62 commit 955da6d
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/libsync/account.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -807,10 +807,14 @@ void Account::deleteAppPassword()
job->setKey(kck);
connect(job, &DeletePasswordJob::finished, [this](Job *incoming) {
auto *deleteJob = dynamic_cast<DeletePasswordJob *>(incoming);
if (deleteJob->error() == NoError)
const auto jobError = deleteJob->error();
if (jobError == NoError) {
qCInfo(lcAccount) << "appPassword deleted from keychain";
else
} else if (jobError == EntryNotFound) {
qCInfo(lcAccount) << "no appPassword entry found";
} else {
qCWarning(lcAccount) << "Unable to delete appPassword from keychain" << deleteJob->errorString();
}

// Allow storing a new app password on re-login
_wroteAppPassword = false;
Expand Down

0 comments on commit 955da6d

Please sign in to comment.