From a3f6576084fc2d0b7e5b95bffadc532d72145111 Mon Sep 17 00:00:00 2001 From: Erik Johnston Date: Fri, 4 Nov 2016 10:48:20 +0000 Subject: Remove unused but buggy function --- synapse/storage/pusher.py | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) (limited to 'synapse') diff --git a/synapse/storage/pusher.py b/synapse/storage/pusher.py index 8f5f8f24a9..5d1cb72a32 100644 --- a/synapse/storage/pusher.py +++ b/synapse/storage/pusher.py @@ -137,17 +137,7 @@ class PusherStore(SQLBaseStore): @cachedInlineCallbacks(num_args=1, max_entries=15000) def get_if_user_has_pusher(self, user_id): - result = yield self._simple_select_many_batch( - table='pushers', - keyvalues={ - 'user_name': 'user_id', - }, - retcol='user_name', - desc='get_if_user_has_pusher', - allow_none=True, - ) - - defer.returnValue(bool(result)) + raise NotImplementedError() @cachedList(cached_method_name="get_if_user_has_pusher", list_name="user_ids", num_args=1, inlineCallbacks=True) -- cgit 1.4.1 From 63772443e6d03afeafffabee78c27b02f996faa3 Mon Sep 17 00:00:00 2001 From: Erik Johnston Date: Fri, 4 Nov 2016 10:53:42 +0000 Subject: Comment --- synapse/storage/pusher.py | 1 + 1 file changed, 1 insertion(+) (limited to 'synapse') diff --git a/synapse/storage/pusher.py b/synapse/storage/pusher.py index 5d1cb72a32..8cc9f0353b 100644 --- a/synapse/storage/pusher.py +++ b/synapse/storage/pusher.py @@ -137,6 +137,7 @@ class PusherStore(SQLBaseStore): @cachedInlineCallbacks(num_args=1, max_entries=15000) def get_if_user_has_pusher(self, user_id): + # This only exists for the cachedList decorator raise NotImplementedError() @cachedList(cached_method_name="get_if_user_has_pusher", -- cgit 1.4.1