From a85e2625cdbeb83da78e15d4df0fa96813d78c54 Mon Sep 17 00:00:00 2001 From: Matthew Hodgson Date: Tue, 18 Sep 2018 14:12:47 +0100 Subject: [PATCH] unhardcode m.room.avatar --- synapse/handlers/room_list.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/synapse/handlers/room_list.py b/synapse/handlers/room_list.py index 38e1737ec9..c73622ba7b 100644 --- a/synapse/handlers/room_list.py +++ b/synapse/handlers/room_list.py @@ -314,7 +314,7 @@ class RoomListHandler(BaseHandler): EventTypes.CanonicalAlias, EventTypes.RoomHistoryVisibility, EventTypes.GuestAccess, - "m.room.avatar", + EventTypes.RoomAvatar, ) ]) @@ -367,7 +367,7 @@ class RoomListHandler(BaseHandler): guest = guest_event.content.get("guest_access", None) result["guest_can_join"] = guest == "can_join" - avatar_event = current_state.get(("m.room.avatar", "")) + avatar_event = current_state.get((EventTypes.RoomAvatar, "")) if avatar_event: avatar_url = avatar_event.content.get("url", None) if avatar_url: