Skip to content

Commit

Permalink
Authenticate by session.
Browse files Browse the repository at this point in the history
  • Loading branch information
davedash committed Oct 28, 2010
1 parent a4eec8b commit 28a8514
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions apps/api/authentication.py
Expand Up @@ -13,9 +13,14 @@ class AMOOAuthAuthentication(authentication.OAuthAuthentication):
"""^^^MOO!!! Adds amo_user to the request object."""

def is_authenticated(self, request):
if request.user.is_authenticated():
return True

rv = super(AMOOAuthAuthentication, self).is_authenticated(request)

if rv:
ACLMiddleware().process_request(request)

return rv

def challenge(self, request):
Expand Down

0 comments on commit 28a8514

Please sign in to comment.