Apply suggestions from code review
Co-authored-by: Eric Eastwood <erice@element.io>
This commit is contained in:
@@ -309,6 +309,8 @@ class RoomMemberHandler(metaclass=abc.ABCMeta):
|
||||
# the table `current_state_events` and `get_current_state_events` is `None`.
|
||||
await self.store.forget(user_id, room_id)
|
||||
|
||||
# If everyone locally has left the room, then there is no reason for us to keep the
|
||||
# room around and we automatically purge room after a little bit
|
||||
if self._purge_retention_period and await self.store.is_locally_forgotten_room(
|
||||
room_id
|
||||
):
|
||||
|
||||
@@ -1343,7 +1343,7 @@ class RoomMemberWorkerStore(EventsWorkerStore, CacheInvalidationWorkerStore):
|
||||
)
|
||||
|
||||
async def get_rooms_to_purge(self) -> List[Dict[str, Any]]:
|
||||
"""Returns all rooms to shutdown/purge. This includes those that has
|
||||
"""Returns all rooms to shutdown/purge. This includes those that have
|
||||
been interrupted by a stop/restart of synapse, but also scheduled ones
|
||||
like locally forgotten rooms.
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user