forked from p15670423/monkey
Agent: Lock RelayUserHandler.has_*_users()
This commit is contained in:
parent
90dcb0a91e
commit
e2736a9273
|
@ -76,6 +76,7 @@ class RelayUserHandler:
|
|||
"""
|
||||
Return whether or not we have any potential users.
|
||||
"""
|
||||
with self._lock:
|
||||
self._potential_users = dict(
|
||||
filter(lambda ru: not ru[1].timer.is_expired(), self._potential_users.items())
|
||||
)
|
||||
|
@ -86,6 +87,7 @@ class RelayUserHandler:
|
|||
"""
|
||||
Return whether or not we have any relay users.
|
||||
"""
|
||||
with self._lock:
|
||||
self._relay_users = dict(
|
||||
filter(lambda ru: not ru[1].timer.is_expired(), self._relay_users.items())
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue