mirror of
https://gitlab.com/etc404/software-engineering-project.git
synced 2026-05-10 20:52:58 +00:00
more checks and stuff for verification
This commit is contained in:
@@ -25,6 +25,11 @@ public class EmailController {
|
||||
if (emailService.isValidEmail(email) == false) {
|
||||
return ResponseEntity.status(429).body("Invalid Email Detected.");
|
||||
}
|
||||
|
||||
if (emailService.isEmailTaken(email)) {
|
||||
return ResponseEntity.status(409).body("An account with this email already exists.");
|
||||
}
|
||||
|
||||
return ResponseEntity.ok().build();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user