Check that somethign has happend before running the selects

This commit is contained in:
Mark Haines 2016-04-27 11:54:13 +01:00
parent 71df327190
commit 871357d539
3 changed files with 14 additions and 2 deletions

View file

@ -391,6 +391,9 @@ class ReceiptsStore(SQLBaseStore):
)
def get_all_updated_receipts(self, last_id, current_id, limit=None):
if last_id == current_id:
return defer.succeed([])
def get_all_updated_receipts_txn(txn):
sql = (
"SELECT stream_id, room_id, receipt_type, user_id, event_id, data"