summary refs log tree commit diff
path: root/synapse/storage/roommember.py
diff options
context:
space:
mode:
authorPaul "LeoNerd" Evans <paul@matrix.org>2014-09-12 13:57:24 +0100
committerPaul "LeoNerd" Evans <paul@matrix.org>2014-09-12 14:28:07 +0100
commite53d77b5017e823506484bbb95964b4d97f3e2a1 (patch)
treee1408272effff81c8c8f87b243ecb64a59b16bc1 /synapse/storage/roommember.py
parentAdd a better _store_room_member_txn() method that takes separated fields inst... (diff)
downloadsynapse-e53d77b5017e823506484bbb95964b4d97f3e2a1.tar.xz
Add a .runInteraction() method on SQLBaseStore itself to wrap the .db_pool
Diffstat (limited to 'synapse/storage/roommember.py')
-rw-r--r--synapse/storage/roommember.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/storage/roommember.py b/synapse/storage/roommember.py
index b357dc3058..8cbc15356d 100644
--- a/synapse/storage/roommember.py
+++ b/synapse/storage/roommember.py
@@ -71,6 +71,11 @@ class RoomMemberStore(SQLBaseStore):
 
             txn.execute(sql, (room_id, domain))
 
+    def store_room_member(self, user_id, room_id, event_id, membership):
+        return self.runInteraction(self._store_room_member_txn,
+            user_id, user_id, room_id, event_id, membership
+        )
+
     @defer.inlineCallbacks
     def get_room_member(self, user_id, room_id):
         """Retrieve the current state of a room member.