From: Instrumental Date: Wed, 29 May 2019 14:32:51 +0000 (-0500) Subject: fix minor SONAR bug X-Git-Tag: 2.1.15~39 X-Git-Url: https://gerrit.onap.org/r/gitweb?p=aaf%2Fauthz.git;a=commitdiff_plain;h=ba331a70f03bb5bf93fdb83a1ff221bdbf817749 fix minor SONAR bug Issue-ID: AAF-835 Change-Id: I46bc1fcd083a26fe45f10f6f69913840fe4cdbaf Signed-off-by: Instrumental --- diff --git a/cadi/aaf/src/main/java/org/onap/aaf/cadi/register/RegistrationCreator.java b/cadi/aaf/src/main/java/org/onap/aaf/cadi/register/RegistrationCreator.java index 5221d8ea..f4e0a688 100644 --- a/cadi/aaf/src/main/java/org/onap/aaf/cadi/register/RegistrationCreator.java +++ b/cadi/aaf/src/main/java/org/onap/aaf/cadi/register/RegistrationCreator.java @@ -99,7 +99,8 @@ public class RegistrationCreator { if (protocol!=null) { locate.setProtocol(protocol); List ls = locate.getSubprotocol(); - if(ls==null || ls.isEmpty()) { + // ls cannot be null, per generated getSubprotocol code + if(ls.isEmpty()) { String subprotocols = access.getProperty(Config.AAF_LOCATOR_SUBPROTOCOL + dot_le, null); if(subprotocols==null) { subprotocols = access.getProperty(Config.CADI_PROTOCOLS, null);