fix automatic logout on auth failure not working

This commit is contained in:
Damien Elmes 2020-08-03 10:24:49 +10:00
parent a991364bfb
commit d9b6793616

View File

@ -61,7 +61,7 @@ def get_sync_status(mw: aqt.main.AnkiQt, callback: Callable[[SyncStatus], None])
def handle_sync_error(mw: aqt.main.AnkiQt, err: Exception):
if isinstance(err, SyncError):
if err.kind == SyncErrorKind.AUTH_FAILED:
if err.kind() == SyncErrorKind.AUTH_FAILED:
mw.pm.clear_sync_auth()
elif isinstance(err, Interrupted):
# no message to show