implemented testing of per user throttling

This commit is contained in:
markotibold 2011-06-11 01:48:10 +02:00
parent 63d086ea11
commit 8ef333a29f

View File

@ -105,7 +105,7 @@ class PerUserThrottling(BasePermission):
(num_requests, duration) = getattr(self.view, 'throttle', (0, 0))
if user.is_authenticated():
ident = str(auth)
ident = str(user)
else:
ident = self.view.request.META.get('REMOTE_ADDR', None)