code: def get_user(self, request):
          
          try:
              return User.objects.get(username=request.data.get('username'),
                                      is_active=True)
          except User.DoesNotExist:
              return None
docs: return active user or ``None``