From 7879a9920635c36f626ab5070041a8c795e8b65d Mon Sep 17 00:00:00 2001 From: Oleg Zhurakousky Date: Thu, 25 Aug 2016 17:41:44 -0400 Subject: [PATCH] NIFI-2675 fixed NPE in template generation This closes #951. Signed-off-by: Andy LoPresto --- .../main/java/org/apache/nifi/web/api/dto/FlowSnippetDTO.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-client-dto/src/main/java/org/apache/nifi/web/api/dto/FlowSnippetDTO.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-client-dto/src/main/java/org/apache/nifi/web/api/dto/FlowSnippetDTO.java index 0ba10a134f..536c412e8b 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-client-dto/src/main/java/org/apache/nifi/web/api/dto/FlowSnippetDTO.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-client-dto/src/main/java/org/apache/nifi/web/api/dto/FlowSnippetDTO.java @@ -214,7 +214,7 @@ public class FlowSnippetDTO { Map map = csDTO.getDescriptors(); Map props = csDTO.getProperties(); for (Entry entry : map.entrySet()) { - if (entry.getValue().getIdentifiesControllerService() != null) { + if (entry.getValue().getIdentifiesControllerService() != null && props.get(entry.getKey()) != null) { String key = entry.getKey(); String value = props.get(key); id = UUID.fromString(value);