mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-03 12:14:50 -04:00
Fix a KeyError in the synchrotron presence
This commit is contained in:
parent
e4134c5e13
commit
4a5bbb1941
1 changed files with 4 additions and 1 deletions
|
@ -187,7 +187,10 @@ class SynchrotronPresence(object):
|
||||||
yield self._send_syncing_users_now()
|
yield self._send_syncing_users_now()
|
||||||
|
|
||||||
def _end():
|
def _end():
|
||||||
if affect_presence:
|
# We check that the user_id is in user_to_num_current_syncs because
|
||||||
|
# user_to_num_current_syncs may have been cleared if we are
|
||||||
|
# shutting down.
|
||||||
|
if affect_presence and user_id in self.user_to_num_current_syncs:
|
||||||
self.user_to_num_current_syncs[user_id] -= 1
|
self.user_to_num_current_syncs[user_id] -= 1
|
||||||
|
|
||||||
@contextlib.contextmanager
|
@contextlib.contextmanager
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue