diff --git a/src/backend/nio_callbacks.py b/src/backend/nio_callbacks.py index 0b262cd9..f3565c1c 100644 --- a/src/backend/nio_callbacks.py +++ b/src/backend/nio_callbacks.py @@ -380,6 +380,10 @@ class NioCallbacks: async def onUnknownEvent(self, room, ev) -> None: + if self.client.backend.ui_settings["hideUnknownEvents"]: + self.client.skipped_events[room.room_id] += 1 + return + co = f"%1 sent an unsupported {ev.type} event" await self.client.register_nio_event(room, ev, content=co) diff --git a/src/backend/user_files.py b/src/backend/user_files.py index 65e96023..0eb58205 100644 --- a/src/backend/user_files.py +++ b/src/backend/user_files.py @@ -214,6 +214,7 @@ class UISettings(JSONDataFile): "collapseSidePanesUnderWindowWidth": 400, "hideProfileChangeEvents": True, "hideMembershipEvents": False, + "hideUnknownEvents": False, "theme": "Midnight.qpl", "writeAliases": {}, "media": {