forked from Archives/Athou_commafeed
allow users without email to change their profile (#1184)
This commit is contained in:
@@ -207,7 +207,7 @@ public class UserREST {
|
|||||||
return Response.status(Status.FORBIDDEN).build();
|
return Response.status(Status.FORBIDDEN).build();
|
||||||
}
|
}
|
||||||
|
|
||||||
Optional<User> login = userService.login(user.getEmail(), request.getCurrentPassword());
|
Optional<User> login = userService.login(user.getName(), request.getCurrentPassword());
|
||||||
if (login.isEmpty()) {
|
if (login.isEmpty()) {
|
||||||
throw new BadRequestException("invalid password");
|
throw new BadRequestException("invalid password");
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user