summary refs log tree commit diff
path: root/synapse/api/auth.py
diff options
context:
space:
mode:
authorLuke Barnard <lukeb@openmarket.com>2016-10-20 12:04:54 +0100
committerLuke Barnard <lukeb@openmarket.com>2016-10-20 12:04:54 +0100
commitf09db236b1867a20ef1328af40a2422bca35944e (patch)
treefbb76e62a298621c517934d6a8c32943509e6c31 /synapse/api/auth.py
parentflake8 (diff)
downloadsynapse-f09db236b1867a20ef1328af40a2422bca35944e.tar.xz
as_user->app_service, less redundant comments, better positioned comments
Diffstat (limited to 'synapse/api/auth.py')
-rw-r--r--synapse/api/auth.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/api/auth.py b/synapse/api/auth.py
index 5fc0150bdc..154af6728a 100644
--- a/synapse/api/auth.py
+++ b/synapse/api/auth.py
@@ -603,11 +603,11 @@ class Auth(object):
         """
         # Can optionally look elsewhere in the request (e.g. headers)
         try:
-            user_id, as_user = yield self._get_appservice_user_id(request)
+            user_id, app_service = yield self._get_appservice_user_id(request)
             if user_id:
                 request.authenticated_entity = user_id
                 defer.returnValue(
-                    synapse.types.create_requester(user_id, as_user=as_user)
+                    synapse.types.create_requester(user_id, app_service=app_service)
                 )
 
             access_token = get_access_token_from_request(
@@ -646,7 +646,7 @@ class Auth(object):
             request.authenticated_entity = user.to_string()
 
             defer.returnValue(synapse.types.create_requester(
-                user, token_id, is_guest, device_id, as_user=as_user))
+                user, token_id, is_guest, device_id, app_service=app_service))
         except KeyError:
             raise AuthError(
                 self.TOKEN_NOT_FOUND_HTTP_STATUS, "Missing access token.",