From 9b8317e9be83e8ca011955a0660398b0c1f6e0be Mon Sep 17 00:00:00 2001 From: Arindam Mondal Date: Tue, 30 Apr 2019 15:04:26 +0900 Subject: Sonar fix NullPointerException Issue-ID: SO-1829 Change-Id: I2b09733698391607989c2289b8c9f8ba5cdfabe4 Signed-off-by: arind.mondal --- .../so/bpmn/infrastructure/pnf/dmaap/PnfEventReadyDmaapClient.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'bpmn/so-bpmn-infrastructure-common') diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/dmaap/PnfEventReadyDmaapClient.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/dmaap/PnfEventReadyDmaapClient.java index cce476f4d8..9f8a456002 100644 --- a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/dmaap/PnfEventReadyDmaapClient.java +++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/dmaap/PnfEventReadyDmaapClient.java @@ -140,7 +140,9 @@ public class PnfEventReadyDmaapClient implements DmaapClient { registerClientResponse(idList.get(0), EntityUtils.toString(response.getEntity(), "UTF-8")); } - idList.forEach(this::informAboutPnfReadyIfPnfCorrelationIdFound); + if (idList != null) { + idList.forEach(this::informAboutPnfReadyIfPnfCorrelationIdFound); + } } catch (IOException e) { logger.error("Exception caught during sending rest request to dmaap for listening event topic", e); } finally { -- cgit 1.2.3-korg