Bug fixes #113

Merged
Patrick_Pluto merged 5 commits from sageTheDm/interstellar_ai:main into main 2024-10-08 07:45:34 +02:00
Showing only changes of commit 601b0324b8 - Show all commits

View file

@ -79,12 +79,16 @@ const Login: React.FC = () => {
// Function to handle account creation
const handleCreateAccount = async () => {
const success = await createAccount(newAccountName, newAccountEmail, newAccountPassword);
if (success) {
alert('Account created successfully! You can now log in.');
toggleSignUpPopup(); // Close sign-up popup
if (newAccountName !== "" && newAccountEmail !== "" && newAccountPassword !== "") {
const success = await createAccount(newAccountName, newAccountEmail, newAccountPassword);
if (success) {
alert('Account created successfully! You can now log in.');
toggleSignUpPopup(); // Close sign-up popup
} else {
alert('Account creation failed. Please try again.');
}
} else {
alert('Account creation failed. Please try again.');
alert('Account creation failed. Please do not leave any field empty.');
}
};