Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Clean up an indirect reference to the homeserver datastore (#11914)
Browse files Browse the repository at this point in the history
  • Loading branch information
anoadragon453 authored Feb 7, 2022
1 parent 0c4878c commit e03dde2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions changelog.d/11914.misc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Various refactors to the typing notifications code.
4 changes: 2 additions & 2 deletions synapse/handlers/typing.py
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,7 @@ def process_replication_rows(

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:
#
Expand Down Expand Up @@ -487,7 +487,7 @@ async def get_new_events_as(
continue

if not await service.matches_user_in_member_list(
room_id, handler.store
room_id, self._main_store
):
continue

Expand Down

0 comments on commit e03dde2

Please sign in to comment.