fix bug with failed login log

This commit is contained in:
AlanCoding 2017-01-03 10:12:04 -05:00
parent 2afdf35375
commit 60ea0bdf92

View File

@ -603,7 +603,7 @@ class AuthTokenView(APIView):
return Response({'token': token.key, 'expires': token.expires}, headers=headers)
if 'username' in request.data:
logger.warning(smart_text(u"Login failed for user {}".format(request.data['username'])),
user=dict(actor=request.data['username']))
extra=dict(actor=request.data['username']))
return Response(serializer.errors, status=status.HTTP_400_BAD_REQUEST)