KeycloakErrorHandler NullPointerException String.toLowerCase() because message is null
Closes #22958 Signed-off-by: Douglas Palmer <dpalmer@redhat.com>
This commit is contained in:
parent
fe48afc1dc
commit
f9665acc29
1 changed files with 1 additions and 1 deletions
|
@ -81,7 +81,7 @@ public class PersistenceExceptionConverter implements InvocationHandler {
|
|||
public static ModelException convert(Throwable t) {
|
||||
final Predicate<Throwable> checkDuplicationMessage = throwable -> {
|
||||
final String message = throwable.getCause() != null ? throwable.getCause().getMessage() : throwable.getMessage();
|
||||
return message.toLowerCase().contains("duplicate");
|
||||
return message == null ? false : message.toLowerCase().contains("duplicate");
|
||||
};
|
||||
|
||||
Predicate<Throwable> throwModelDuplicateEx = throwable ->
|
||||
|
|
Loading…
Reference in a new issue