fix: change status code for EmailNotVerifiedException
Some checks failed
CI / Get Changed Files (pull_request) Successful in 14s
CI / Docker frontend validation (pull_request) Successful in 19s
CI / oxlint (pull_request) Successful in 27s
CI / eslint (pull_request) Failing after 33s
CI / prettier (pull_request) Failing after 29s
CI / Checkstyle Main (pull_request) Successful in 1m21s
CI / Docker backend validation (pull_request) Successful in 1m25s
CI / test-build (pull_request) Successful in 41s
Some checks failed
CI / Get Changed Files (pull_request) Successful in 14s
CI / Docker frontend validation (pull_request) Successful in 19s
CI / oxlint (pull_request) Successful in 27s
CI / eslint (pull_request) Failing after 33s
CI / prettier (pull_request) Failing after 29s
CI / Checkstyle Main (pull_request) Successful in 1m21s
CI / Docker backend validation (pull_request) Successful in 1m25s
CI / test-build (pull_request) Successful in 41s
This commit is contained in:
parent
d2225decc1
commit
db9fe84259
1 changed files with 1 additions and 1 deletions
|
@ -36,6 +36,6 @@ public class GlobalExceptionHandler {
|
||||||
@ExceptionHandler(EmailNotVerifiedException.class)
|
@ExceptionHandler(EmailNotVerifiedException.class)
|
||||||
public ResponseEntity<?> handleEmailNotVerifiedException(EmailNotVerifiedException ex, WebRequest request) {
|
public ResponseEntity<?> handleEmailNotVerifiedException(EmailNotVerifiedException ex, WebRequest request) {
|
||||||
ErrorDetails errorDetails = new ErrorDetails(new Date(), ex.getMessage(), request.getDescription(false));
|
ErrorDetails errorDetails = new ErrorDetails(new Date(), ex.getMessage(), request.getDescription(false));
|
||||||
return new ResponseEntity<>(errorDetails, HttpStatus.BAD_REQUEST);
|
return new ResponseEntity<>(errorDetails, HttpStatus.UNAUTHORIZED);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Reference in a new issue