diff --git a/src/backend/matrix_client.py b/src/backend/matrix_client.py index 8b5a9aa0..a7c23c71 100644 --- a/src/backend/matrix_client.py +++ b/src/backend/matrix_client.py @@ -968,11 +968,12 @@ class MatrixClient(nio.AsyncClient): for sync_id, model in self.models.items(): if not (isinstance(sync_id, tuple) and + len(sync_id) == 3 and sync_id[0] == self.user_id and sync_id[2] == "events"): continue - _, _, room_id = sync_id + _, room_id, _ = sync_id for ev in model.values(): room = self.all_rooms[room_id] diff --git a/src/gui/Dialogs/ImportKeys.qml b/src/gui/Dialogs/ImportKeys.qml index 907a499d..5f1da97b 100644 --- a/src/gui/Dialogs/ImportKeys.qml +++ b/src/gui/Dialogs/ImportKeys.qml @@ -36,7 +36,9 @@ HFileDialogOpener { importing = false callback(true) - }, (type, args) => { + }, (type, args, error, traceback, uuid) => { + let unknown = false + callback( type === "EncryptionError" ? false : @@ -53,8 +55,13 @@ HFileDialogOpener { type === "PermissionError" ? qsTr("No permission to read this file") : - qsTr("Unknown error: %1 - %2").arg(type).arg(args) + ( + unknown = true, + qsTr("Unknown error: %1 - %2").arg(type).arg(args) + ) ) + + if (unknown) utils.showError(type, traceback, uuid) }) } }