Skip to content
Snippets Groups Projects
Commit e2c46ed8 authored by Erik Johnston's avatar Erik Johnston
Browse files

Move deletion from table inside txn

parent 04710cc2
No related branches found
No related tags found
No related merge requests found
......@@ -254,10 +254,13 @@ class StatsStore(StateDeltasStore):
{"room_id": room_id, "token": current_token},
)
# We've finished a room. Delete it from the table.
self._simple_delete_one_txn(
txn, TEMP_TABLE + "_rooms", {"room_id": room_id},
)
yield self.runInteraction("update_room_stats", _fetch_data)
# We've finished a room. Delete it from the table.
yield self._simple_delete_one(TEMP_TABLE + "_rooms", {"room_id": room_id})
# Update the remaining counter.
progress["remaining"] -= 1
yield self.runInteraction(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment