Invalid credentials
Opened this issue · 1 comments
NdauwaRafael commented
Invalid credentials
danngalann commented
From a YouTube comment:
Double check your indentation of the create method of the RegisterSerializer class.
I found out that my create method was part of the class Meta instead of RegisterSerializer class. The result is that the create method was never called during registration and the password was not hashed in the database.
Happened the same to me. RegisterSerializer was returning the password without hashing, so it wast being stored in plan text. On login, a hashed password was being compared to the stored plain text password and, since they do not match, it returns Invalid Credentials.