Don't hit DB for noop replications queries

This commit is contained in:
Erik Johnston 2016-06-08 11:33:30 +01:00
parent e0fda29f94
commit 1a815fb04f
5 changed files with 15 additions and 0 deletions

View file

@ -118,6 +118,9 @@ class PresenceStore(SQLBaseStore):
)
def get_all_presence_updates(self, last_id, current_id):
if last_id == current_id:
return defer.succeed([])
def get_all_presence_updates_txn(txn):
sql = (
"SELECT stream_id, user_id, state, last_active_ts,"