mirror of
https://mau.dev/maunium/synapse.git
synced 2024-12-14 04:43:46 +01:00
Rename _execute_query
This commit is contained in:
parent
937c175029
commit
2529f2bc01
4 changed files with 4 additions and 4 deletions
|
@ -119,7 +119,7 @@ class DataStore(RoomDataStore, RoomMemberStore, MessageStore, RoomStore,
|
||||||
else:
|
else:
|
||||||
args = (room_id, )
|
args = (room_id, )
|
||||||
|
|
||||||
results = yield self._execute_query(sql, *args)
|
results = yield self._execute_and_decode(sql, *args)
|
||||||
|
|
||||||
defer.returnValue(
|
defer.returnValue(
|
||||||
|
|
||||||
|
|
|
@ -71,7 +71,7 @@ class SQLBaseStore(object):
|
||||||
|
|
||||||
return self._db_pool.runInteraction(interaction)
|
return self._db_pool.runInteraction(interaction)
|
||||||
|
|
||||||
def _execut_query(self, query, *args):
|
def _execute_and_decode(self, query, *args):
|
||||||
return self._execute(self.cursor_to_dict, *args)
|
return self._execute(self.cursor_to_dict, *args)
|
||||||
|
|
||||||
# "Simple" SQL API methods that operate on a single table with no JOINs,
|
# "Simple" SQL API methods that operate on a single table with no JOINs,
|
||||||
|
|
|
@ -39,7 +39,7 @@ class FeedbackStore(SQLBaseStore):
|
||||||
"WHERE feedback.target_event_id = ? "
|
"WHERE feedback.target_event_id = ? "
|
||||||
)
|
)
|
||||||
|
|
||||||
rows = yield self._execute_query(sql, event_id)
|
rows = yield self._execute_and_decode(sql, event_id)
|
||||||
|
|
||||||
defer.returnValue(
|
defer.returnValue(
|
||||||
[
|
[
|
||||||
|
|
|
@ -141,6 +141,6 @@ class RoomMemberStore(SQLBaseStore):
|
||||||
"WHERE %s "
|
"WHERE %s "
|
||||||
) % (where_clause,)
|
) % (where_clause,)
|
||||||
|
|
||||||
rows = yield self._execute_query(sql, where_values)
|
rows = yield self._execute_and_decode(sql, where_values)
|
||||||
results = [self._parse_event_from_row(r) for r in rows]
|
results = [self._parse_event_from_row(r) for r in rows]
|
||||||
defer.returnValue(results)
|
defer.returnValue(results)
|
||||||
|
|
Loading…
Reference in a new issue