From 246a2d35adcdea8ca5c7b3eba75d01d5f0e8c780 Mon Sep 17 00:00:00 2001 From: "raviteja.karumuri" Date: Tue, 4 Apr 2023 01:14:11 +0100 Subject: [CPS] Fix SonarQube Violations / Improve Coverage - Recurring task Issue-ID: CPS-475 Signed-off-by: raviteja.karumuri Change-Id: I7429e1563608159b5592a2dc52ab5383f11a8ab3 --- .../onap/cps/ncmp/api/impl/event/lcm/LcmEventsCreatorHelper.java | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'cps-ncmp-service/src/main') diff --git a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/event/lcm/LcmEventsCreatorHelper.java b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/event/lcm/LcmEventsCreatorHelper.java index 40f70b9c68..852323df7d 100644 --- a/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/event/lcm/LcmEventsCreatorHelper.java +++ b/cps-ncmp-service/src/main/java/org/onap/cps/ncmp/api/impl/event/lcm/LcmEventsCreatorHelper.java @@ -1,6 +1,6 @@ /* * ============LICENSE_START======================================================= - * Copyright (C) 2022 Nordix Foundation + * Copyright (C) 2022-2023 Nordix Foundation * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -177,10 +177,8 @@ public class LcmEventsCreatorHelper { private static boolean hasDataSyncEnabledFlagChanged(final NcmpServiceCmHandle targetNcmpServiceCmHandle, final NcmpServiceCmHandle existingNcmpServiceCmHandle) { - final Boolean targetDataSyncFlag = targetNcmpServiceCmHandle.getCompositeState() == null - ? null : targetNcmpServiceCmHandle.getCompositeState().getDataSyncEnabled(); - final Boolean existingDataSyncFlag = existingNcmpServiceCmHandle.getCompositeState() == null - ? null : existingNcmpServiceCmHandle.getCompositeState().getDataSyncEnabled(); + final Boolean targetDataSyncFlag = targetNcmpServiceCmHandle.getCompositeState().getDataSyncEnabled(); + final Boolean existingDataSyncFlag = existingNcmpServiceCmHandle.getCompositeState().getDataSyncEnabled(); if (targetDataSyncFlag == null) { return existingDataSyncFlag != null; -- cgit 1.2.3-korg