summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
Diffstat (limited to 'synapse')
-rw-r--r--synapse/handlers/room.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/handlers/room.py b/synapse/handlers/room.py
index b02056dc63..c103488076 100644
--- a/synapse/handlers/room.py
+++ b/synapse/handlers/room.py
@@ -1033,10 +1033,10 @@ class RoomContextHandler:
         users = await self.store.get_users_in_room(room_id)
         is_peeking = user.to_string() not in users
 
-        def filter_evts(events):
+        async def filter_evts(events):
             if use_admin_priviledge:
-                return maybe_awaitable(events)
-            return filter_events_for_client(
+                return events
+            return await filter_events_for_client(
                 self.storage, user.to_string(), events, is_peeking=is_peeking
             )