RajaThor commited on
Commit
d668f45
·
verified ·
1 Parent(s): 584de01

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +16 -16
app.py CHANGED
@@ -271,22 +271,22 @@ def authenticate_user_ui():
271
  else:
272
  st.error("Authentication failed. Please check your email/username and password.")
273
  elif option == "Sign-Up":
274
- st.write("## Sign-Up")
275
- email = st.text_input("Email", help="Enter your email address")
276
- username = st.text_input("Username", help="Enter your desired username")
277
- password = st.text_input("Password", type="password", help="Enter your password")
278
- confirm_password = st.text_input("Confirm Password", type="password", help="Re-enter your password for confirmation")
279
- if st.button("Sign-Up"):
280
- if not email or not username or not password or not confirm_password:
281
- st.error("Please fill all the fields.")
282
- elif password != confirm_password:
283
- st.error("Passwords do not match.")
284
- else:
285
- success, uid = create_user(email, username, password) # Include username argument here
286
- if success:
287
- st.success(f"User with UID: {uid} created successfully! You can now log in.")
288
- else:
289
- st.error("User creation failed. Please try again.")
290
 
291
  # Log out user
292
  def logout():
 
271
  else:
272
  st.error("Authentication failed. Please check your email/username and password.")
273
  elif option == "Sign-Up":
274
+ st.write("## Sign-Up")
275
+ email = st.text_input("Email", help="Enter your email address")
276
+ username = st.text_input("Username", help="Enter your desired username")
277
+ password = st.text_input("Password", type="password", help="Enter your password")
278
+ confirm_password = st.text_input("Confirm Password", type="password", help="Re-enter your password for confirmation")
279
+ if st.button("Sign-Up"):
280
+ if not email or not username or not password or not confirm_password:
281
+ st.error("Please fill all the fields.")
282
+ elif password != confirm_password:
283
+ st.error("Passwords do not match.")
284
+ else:
285
+ success, uid = create_user(email, username, password) # Include username argument here
286
+ if success:
287
+ st.success(f"User with UID: {uid} created successfully! You can now log in.")
288
+ else:
289
+ st.error("User creation failed. Please try again.")
290
 
291
  # Log out user
292
  def logout():