a user cant invite himself now
This commit is contained in:
parent
896702b8f8
commit
d00d310449
@ -767,6 +767,10 @@ public class Controller {
|
|||||||
if (invitedUser == null) {
|
if (invitedUser == null) {
|
||||||
return ResponseEntity.status(404).body("Es gibt keinen Benutzer mit dieser email.");
|
return ResponseEntity.status(404).body("Es gibt keinen Benutzer mit dieser email.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (invitedUser == user) {
|
||||||
|
return ResponseEntity.status(404).body("Du kannst dich selbst nicht einladen.");
|
||||||
|
}
|
||||||
//----------------------
|
//----------------------
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user