Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't remove cache when token is invalid #381

Merged
merged 1 commit into from
Aug 19, 2023
Merged

Conversation

feiniks
Copy link
Contributor

@feiniks feiniks commented Aug 19, 2023

No description provided.

@@ -77,7 +77,7 @@ void RemoteWipeService::onRequestFailed(const ApiError& error)
// but we only handle this error here to avoid complicate code since it is
// general enough.
if (error.type() == ApiError::HTTP_ERROR && error.httpErrorCode() == 401) {
askDaemonDeleteAccount(req->account());
askDaemonDeleteAccount(req->account(), false);
gui->warningBox(tr("Authorization expired, please re-login"));
gui->accountManager()->disableAccount(req->account());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里应该可以直接调用 account_mgr 的 removeAccount 函数吧?就不用走 askDaemonDeleteAccount。否则 GUI 这里的账号还在,但是底层的账号已经没了,不一致。而且界面上留着这个账号也没用。

@killing killing merged commit d3f186f into master Aug 19, 2023
@killing killing deleted the fix_remove_cache branch August 19, 2023 09:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants