Skip to content

Commit

Permalink
Removed Session auth due to a fix in Anonymous
Browse files Browse the repository at this point in the history
  • Loading branch information
brosner committed Apr 21, 2016
1 parent 3802248 commit aca8629
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions pinax/api/authentication.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,9 @@ def decorator(func):
return decorator


class Session(object):

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


class Anonymous(object):

def authenticate(self, request):
from django.contrib.auth.models import AnonymousUser
return AnonymousUser()
if not request.user.is_authenticated():
from django.contrib.auth.models import AnonymousUser
return AnonymousUser()

0 comments on commit aca8629

Please sign in to comment.