Fixed user/del
This commit is contained in:
parent
710b661b0d
commit
bba0b6d5d2
@ -144,7 +144,7 @@ public class UserController {
|
||||
if (user == null) {
|
||||
return new ResponseEntity<>("User nicht in der Datenbank vorhanden", HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
if(userDAO.deleteAllUserEvents(user.getId())){
|
||||
if(!userDAO.deleteAllUserEvents(user.getId())){
|
||||
return new ResponseEntity<>("User konnte nicht gelöscht werden", HttpStatus.INTERNAL_SERVER_ERROR);
|
||||
}
|
||||
userRepository.delete(user);
|
||||
|
Loading…
Reference in New Issue
Block a user