Enable passing typing stream writers as a list. (#11237)

This makes the typing stream writer config match the other stream writers
that only currently support a single worker.
This commit is contained in:
Nick Barrett 2021-11-03 14:25:47 +00:00 committed by GitHub
parent 2735b3e6f2
commit af54167516
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 24 additions and 16 deletions

View file

@ -138,7 +138,7 @@ class ReplicationCommandHandler:
if isinstance(stream, TypingStream):
# Only add TypingStream as a source on the instance in charge of
# typing.
if hs.config.worker.writers.typing == hs.get_instance_name():
if hs.get_instance_name() in hs.config.worker.writers.typing:
self._streams_to_replicate.append(stream)
continue