diff options
author | Richard van der Hoff <github@rvanderhoff.org.uk> | 2018-02-09 14:11:00 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-09 14:11:00 +0000 |
commit | 10b34dbb9abcc0800db84dae74a244caaea54e2d (patch) | |
tree | aedd171b7d6973ea2f4c76dfb6e8610737da9e4c /synapse/handlers | |
parent | Merge pull request #2856 from matrix-org/erikj/remove_ratelimit (diff) | |
parent | purge: move room_depth update to end (diff) | |
download | synapse-10b34dbb9abcc0800db84dae74a244caaea54e2d.tar.xz |
Merge pull request #2858 from matrix-org/rav/purge_updates
delete_local_events for purge_room_history
Diffstat (limited to 'synapse/handlers')
-rw-r--r-- | synapse/handlers/message.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py index a58fc37fff..4e9752ccbd 100644 --- a/synapse/handlers/message.py +++ b/synapse/handlers/message.py @@ -51,7 +51,7 @@ class MessageHandler(BaseHandler): self.pagination_lock = ReadWriteLock() @defer.inlineCallbacks - def purge_history(self, room_id, event_id): + def purge_history(self, room_id, event_id, delete_local_events=False): event = yield self.store.get_event(event_id) if event.room_id != room_id: @@ -60,7 +60,7 @@ class MessageHandler(BaseHandler): depth = event.depth with (yield self.pagination_lock.write(room_id)): - yield self.store.delete_old_state(room_id, depth) + yield self.store.purge_history(room_id, depth, delete_local_events) @defer.inlineCallbacks def get_messages(self, requester, room_id=None, pagin_config=None, |