From f55e54bc2e76b2e049a1211549e3b37e4956647f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Alcarraz?= Date: Fri, 31 Dec 2021 14:28:35 -0500 Subject: [PATCH] Avoid NPE in BLException.getDetailedMessage. When `getMessage` is null. --- modules/core/src/main/java/org/jpos/ee/BLException.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/core/src/main/java/org/jpos/ee/BLException.java b/modules/core/src/main/java/org/jpos/ee/BLException.java index 21f1e6fa23..d5078d4190 100644 --- a/modules/core/src/main/java/org/jpos/ee/BLException.java +++ b/modules/core/src/main/java/org/jpos/ee/BLException.java @@ -61,8 +61,8 @@ public String getDetail () { return detail; } public String getDetailedMessage () { - StringBuffer sb = new StringBuffer (getMessage()); - + StringBuffer sb = new StringBuffer (); + sb.append(getMessage()); if (detail != null) { sb.append (" ("); sb.append (detail);