diff options
author | franciscovila <javier.paradela.vila@est.tech> | 2021-12-15 17:25:23 +0000 |
---|---|---|
committer | Vasyl Razinkov <vasyl.razinkov@est.tech> | 2021-12-17 10:38:17 +0000 |
commit | df3156cf3602be7de77aa1acf8af758628a9ac00 (patch) | |
tree | c02d282ae8136e8fff60617aac60200b874d99dd | |
parent | e638cd61b3f3a79046b0aaab0f3dabdabd43badc (diff) |
Fix NPE in ToscaElementLifecycleOperation - handlePreviousVersionRelation
Change-Id: I8a0ffe60755788857842f5baa98dd34ccd81f33d
Signed-off-by: franciscovila <javier.paradela.vila@est.tech>
Issue-ID: SDC-2968
fixed review comments
-rw-r--r-- | catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/ToscaElementLifecycleOperation.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/ToscaElementLifecycleOperation.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/ToscaElementLifecycleOperation.java index d46d4a554e..cf2db79871 100644 --- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/ToscaElementLifecycleOperation.java +++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/ToscaElementLifecycleOperation.java @@ -899,7 +899,7 @@ public class ToscaElementLifecycleOperation extends BaseOperation { if (status != JanusGraphOperationStatus.OK) { CommonUtility.addRecordToLog(log, LogLevelEnum.DEBUG, "Failed to create edge with label {} from vertex {} to tosca element vertex {} on graph. Status is {}. ", - EdgeLabelEnum.VERSION, previousCertifiedToscaElement.property(GraphPropertyEnum.UNIQUE_ID.getProperty()), + EdgeLabelEnum.VERSION, null != previousCertifiedToscaElement ? previousCertifiedToscaElement.property(GraphPropertyEnum.UNIQUE_ID.getProperty()) : null, clonedToscaElement.getUniqueId(), status); result = Either.right(DaoStatusConverter.convertJanusGraphStatusToStorageStatus(status)); } |