Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Ensure an auth instance is available to ListMediaInRoom (#5967)
Browse files Browse the repository at this point in the history
  • Loading branch information
anoadragon453 committed Feb 25, 2020
2 parents bf7b7a8 + 0eac707 commit a8c2c54
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelog.d/5967.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix list media admin API always returning an error.
2 changes: 1 addition & 1 deletion synapse/handlers/presence.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ def _persist_unpersisted_changes(self):
self.unpersisted_users_changes = set()

if unpersisted:
logger.info("Persisting %d upersisted presence updates", len(unpersisted))
logger.info("Persisting %d unpersisted presence updates", len(unpersisted))
yield self.store.update_presence(
[self.user_to_current_state[user_id] for user_id in unpersisted]
)
Expand Down
1 change: 1 addition & 0 deletions synapse/rest/admin/media.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ class ListMediaInRoom(RestServlet):

def __init__(self, hs):
self.store = hs.get_datastore()
self.auth = hs.get_auth()

@defer.inlineCallbacks
def on_GET(self, request, room_id):
Expand Down

0 comments on commit a8c2c54

Please sign in to comment.