Skip to content

Commit

Permalink
[chore]: change reset password link
Browse files Browse the repository at this point in the history
- append reset-password/ to HTTP_REFERER

[FInishes 161547181]
  • Loading branch information
meshack-mbuvi authored and david.parseen committed Oct 29, 2018
1 parent 6853dcb commit daf55ce
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions authors/apps/authentication/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,7 @@ def post(self, request):
return Response({"message": "The email you entered does not exist"}, status=status.HTTP_404_NOT_FOUND)

# Get URL for client and include in the email for resetting password
client_url = request.META['HTTP_REFERER'].replace(
"login", "reset-password/")
client_url = request.META['HTTP_REFERER'] + "reset-password/"
# generate token
token = default_token_generator.make_token(user)
# format url and send it in the reset email link
Expand Down

0 comments on commit daf55ce

Please sign in to comment.