Example #1
0
 def __authenticate_user(self, username: str, password: str):
     user = AccountProcessor.get_user_details(username)
     if not user:
         return False
     if not Utility.verify_password(password, user["password"]):
         return False
     return user
Example #2
0
 def __authenticate_user(self, username: str, password: str):
     """ Checks if the user name and password match. It returns the user details
         if they match and returns False if not """
     user = AccountProcessor.get_user_details(username)
     if not user:
         return False
     if not Utility.verify_password(password, user["password"]):
         return False
     return user