Modificacion si un firstName esta nulo
This commit is contained in:
parent
5d0c87d8d6
commit
53aa021001
|
@ -168,7 +168,7 @@ public class AccountResource {
|
|||
public void requestPasswordReset(@RequestBody String mail) {
|
||||
Optional<User> user = userService.requestPasswordReset(mail);
|
||||
if (user.isPresent()) {
|
||||
if (!user.get().getFirstName().equals("IsGoogle")) {
|
||||
if (user.get().getFirstName() == null || (!user.get().getFirstName().equals("IsGoogle"))) {
|
||||
mailService.sendPasswordResetMail(user.get());
|
||||
} else {
|
||||
throw new UserIsGoogleException();
|
||||
|
|
Loading…
Reference in New Issue