sonar Major issues 01/30401/1
authorSnigdha Sucharita Patra <sp00503415@techmahindra.com>
Tue, 6 Feb 2018 08:05:16 +0000 (13:35 +0530)
committerSnigdha Sucharita Patra <sp00503415@techmahindra.com>
Tue, 6 Feb 2018 08:05:16 +0000 (13:35 +0530)
Replace these toUpperCase()/toLowerCase() and equals() calls with a single equalsIgnoreCase() call
Sonar Link:
https://sonar.onap.org/component_issues?id=org.onap.dcaegen2.platform%3Ainventory-api#resolved=false|severities=MAJOR|assignees=Snigdha503415
Location:
src/main/java/io/swagger/api/impl/DcaeServicesApiServiceImpl.java
Line No-108

Change-Id: I7a21f8c847cdbdfe17aa54919859ef60e265caf9
Issue-ID: DCAEGEN2-307
Signed-off-by: Snigdha Sucharita Patra <sp00503415@techmahindra.com>
src/main/java/io/swagger/api/impl/DcaeServicesApiServiceImpl.java

index 90c2435..ae613da 100644 (file)
@@ -105,7 +105,7 @@ public class DcaeServicesApiServiceImpl extends DcaeServicesApiService {
                         LOG.warn(String.format("%s, %s", e.getMessage(), sco.toString()), e);
                     }
                 }
-            } else if (COMPONENT_SOURCE_DATA_BUS_CONTROLLER.equals(sco.getComponentSource().toUpperCase(Locale.ENGLISH))) {
+            } else if (COMPONENT_SOURCE_DATA_BUS_CONTROLLER.equalsIgnoreCase(sco.getComponentSource())) {
                 if (this.databusControllerClient != null) {
                     try {
                         if (this.databusControllerClient.isExists(sco.getComponentId())) {