diff options
author | Kegan Dougal <kegan@matrix.org> | 2015-03-02 10:16:24 +0000 |
---|---|---|
committer | Kegan Dougal <kegan@matrix.org> | 2015-03-02 10:16:24 +0000 |
commit | 3d73383d185b41b9986366da8123255e3a8ce1e0 (patch) | |
tree | 95fdacb46fc8315abfa946bb1979a33fd7bc37a8 /synapse/storage/registration.py | |
parent | PR tweaks: set earlier on and use 'as json' for compat (diff) | |
download | synapse-3d73383d185b41b9986366da8123255e3a8ce1e0.tar.xz |
Modify _simple_select_list to allow an empty WHERE clause. Use it for get_all_rooms and get_all_users.
Diffstat (limited to 'synapse/storage/registration.py')
-rw-r--r-- | synapse/storage/registration.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/synapse/storage/registration.py b/synapse/storage/registration.py index 9c92575c7f..54cd15bc0e 100644 --- a/synapse/storage/registration.py +++ b/synapse/storage/registration.py @@ -93,11 +93,8 @@ class RegistrationStore(SQLBaseStore): ) def get_all_users(self): - query = "SELECT users.name FROM users" - return self._execute( - self.cursor_to_dict, - query - ) + return self._simple_select_list( + table="users", keyvalues=None, retcols=["name"]) def get_user_by_token(self, token): """Get a user from the given access token. |