This commit is contained in:
Pierre Tellier
2025-04-21 18:01:10 +02:00
parent 8403bc0592
commit 6861d07dfc
2 changed files with 20 additions and 2 deletions
MyINPulse-back/src
main
java
enseirb
myinpulse
test
java
enseirb

@ -124,6 +124,7 @@ public class EntrepreneurService {
}
public void validateEntrepreneurById(Long id) {
System.out.println("\nVALIDATING\n");
Optional<Entrepreneur> e = this.entrepreneurRepository.findById(id);
if (e.isEmpty()) {
throw new ResponseStatusException(HttpStatus.NOT_FOUND, "Entrepreneur n'existe pas");