Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added API Route for User Password Change #797

Merged
merged 18 commits into from
Jul 7, 2022

Conversation

siddnikh
Copy link
Contributor

The API route is /api/v1/password_change/
Need to update documentation and frontend.

Co-authored-by: Marmik Patel <44599895+Marmik2003@users.noreply.github.com>
Copy link
Contributor

@Marmik2003 Marmik2003 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment on lines 37 to 41
if not self.object.check_password(serializer.data.get("old_password")):
return Response({"old_password": ["Wrong password entered. Please check your password."]}, status=status.HTTP_400_BAD_REQUEST)
# set_password also hashes the password that the user will get
self.object.set_password(serializer.data.get("new_password"))
self.object.save()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be handled in serializer

siddnikh and others added 3 commits July 3, 2022 20:21
Co-authored-by: Aakash Singh <46787056+sainAk@users.noreply.github.com>
Co-authored-by: Aakash Singh <46787056+sainAk@users.noreply.github.com>
@codecov-commenter
Copy link

codecov-commenter commented Jul 3, 2022

Codecov Report

❗ No coverage uploaded for pull request base (master@84af660). Click here to learn what that means.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master     #797   +/-   ##
=========================================
  Coverage          ?   52.75%           
=========================================
  Files             ?      180           
  Lines             ?     8777           
  Branches          ?        0           
=========================================
  Hits              ?     4630           
  Misses            ?     4147           
  Partials          ?        0           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 84af660...74f6683. Read the comment docs.

@vigneshhari vigneshhari merged commit ce093ea into ohcnetwork:master Jul 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants