RajaThor commited on
Commit
92a95df
·
verified ·
1 Parent(s): 4c2d675

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -51,11 +51,11 @@ def authenticate_user(email, password):
51
  except firebase_admin.auth.UserNotFoundError as e:
52
  print(f"User not found error: {str(e)}")
53
  return False, None
54
- except firebase_admin.auth.InvalidPasswordError as e:
55
- print(f"Invalid password error: {str(e)}")
56
- return False, None
57
- except Exception as e:
58
- print(f"Authentication error: {str(e)}")
59
  return False, None
60
 
61
  # Sign-up Functionality
 
51
  except firebase_admin.auth.UserNotFoundError as e:
52
  print(f"User not found error: {str(e)}")
53
  return False, None
54
+ except firebase_admin.auth.AuthError as e:
55
+ if e.code == 'wrong-password':
56
+ print("Invalid password error")
57
+ else:
58
+ print(f"Authentication error: {str(e)}")
59
  return False, None
60
 
61
  # Sign-up Functionality