fix(oauth): Fix too many arguments error by removing not used token
This commit is contained in:
parent
2c6bb23715
commit
b0c82ce09f
|
@ -188,7 +188,7 @@ class AuthorizeView(views.APIView, oauth_views.AuthorizationView):
|
||||||
except models.Application.DoesNotExist:
|
except models.Application.DoesNotExist:
|
||||||
return self.json_payload({"non_field_errors": ["Invalid application"]}, 400)
|
return self.json_payload({"non_field_errors": ["Invalid application"]}, 400)
|
||||||
|
|
||||||
def redirect(self, redirect_to, application, token=None):
|
def redirect(self, redirect_to, application):
|
||||||
if self.request.is_ajax():
|
if self.request.is_ajax():
|
||||||
# Web client need this to be able to redirect the user
|
# Web client need this to be able to redirect the user
|
||||||
query = urllib.parse.urlparse(redirect_to).query
|
query = urllib.parse.urlparse(redirect_to).query
|
||||||
|
@ -197,7 +197,7 @@ class AuthorizeView(views.APIView, oauth_views.AuthorizationView):
|
||||||
{"redirect_uri": redirect_to, "code": code}, status_code=200
|
{"redirect_uri": redirect_to, "code": code}, status_code=200
|
||||||
)
|
)
|
||||||
|
|
||||||
return super().redirect(redirect_to, application, token)
|
return super().redirect(redirect_to, application)
|
||||||
|
|
||||||
def error_response(self, error, application):
|
def error_response(self, error, application):
|
||||||
if isinstance(error, oauth2_exceptions.FatalClientError):
|
if isinstance(error, oauth2_exceptions.FatalClientError):
|
||||||
|
|
Loading…
Reference in New Issue