diff --git a/src/main/java/SignUpGUI.java b/src/main/java/SignUpGUI.java index 520adb1..babf30d 100644 --- a/src/main/java/SignUpGUI.java +++ b/src/main/java/SignUpGUI.java @@ -56,6 +56,7 @@ public class SignUpGUI extends JFrame implements ActionListener { CreateUser user = CreateUser.createUser(randomUUID.toString(), username, password, birthday); user.saveToJsonFile("user.json"); JOptionPane.showMessageDialog(this, "User signed up successfully!"); + dispose(); } catch (IllegalArgumentException ex) { JOptionPane.showMessageDialog(this, "Error: " + ex.getMessage(), "Sign Up Error", JOptionPane.ERROR_MESSAGE); } diff --git a/user.json b/user.json index e407c0d..5cd130f 100644 --- a/user.json +++ b/user.json @@ -16,5 +16,11 @@ "userName": "asdasdasd", "password": "1231412512", "birthday": "1111111" + }, + { + "id": "f2775f81-564b-4101-8e86-ce879a9e7737", + "userName": "asd", + "password": "asdasdasd", + "birthday": "asd" } ] \ No newline at end of file