summary refs log tree commit diff
diff options
context:
space:
mode:
authorAndrew Morgan <1342360+anoadragon453@users.noreply.github.com>2022-02-07 13:25:09 +0000
committerGitHub <noreply@github.com>2022-02-07 13:25:09 +0000
commite03dde259b741ae824a2569d23ba8bdbc336a54a (patch)
treea50921310f47add9c255ad3fbefb1e200f73bfd5
parentAdd a unit test for users receiving their own device list updates (#11909) (diff)
downloadsynapse-e03dde259b741ae824a2569d23ba8bdbc336a54a.tar.xz
Clean up an indirect reference to the homeserver datastore (#11914)
-rw-r--r--changelog.d/11914.misc1
-rw-r--r--synapse/handlers/typing.py4
2 files changed, 3 insertions, 2 deletions
diff --git a/changelog.d/11914.misc b/changelog.d/11914.misc
new file mode 100644

index 0000000000..c288d43455 --- /dev/null +++ b/changelog.d/11914.misc
@@ -0,0 +1 @@ +Various refactors to the typing notifications code. \ No newline at end of file diff --git a/synapse/handlers/typing.py b/synapse/handlers/typing.py
index e43c22832d..e4bed1c937 100644 --- a/synapse/handlers/typing.py +++ b/synapse/handlers/typing.py
@@ -446,7 +446,7 @@ class TypingWriterHandler(FollowerTypingHandler): class TypingNotificationEventSource(EventSource[int, JsonDict]): def __init__(self, hs: "HomeServer"): - self.hs = hs + self._main_store = hs.get_datastore() self.clock = hs.get_clock() # We can't call get_typing_handler here because there's a cycle: # @@ -487,7 +487,7 @@ class TypingNotificationEventSource(EventSource[int, JsonDict]): continue if not await service.matches_user_in_member_list( - room_id, handler.store + room_id, self._main_store ): continue