move get_user in api_method
authorSofia Papagiannaki <papagian@gmail.com>
Wed, 20 Jun 2012 13:27:37 +0000 (16:27 +0300)
committerSofia Papagiannaki <papagian@gmail.com>
Wed, 20 Jun 2012 13:27:37 +0000 (16:27 +0300)
snf-pithos-app/pithos/api/util.py

index 28ebed9..0da251a 100644 (file)
@@ -886,7 +886,7 @@ def api_method(http_method=None, format_allowed=False, user_required=True):
                         cookie_value = unquote(request.COOKIES.get(COOKIE_NAME, ''))
                         if cookie_value and '|' in cookie_value:
                             token = cookie_value.split('|', 1)[1]
-                    get_user(request, IDENTITY_BASEURL, AUTHENTICATION_USERS, token)
+                    get_user(request, AUTHENTICATION_URL, AUTHENTICATION_USERS, token)
                     if  getattr(request, 'user', None) is None:
                         raise Unauthorized('Access denied')