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-93
Change-Id: I5d7ec72053255053ebf2c0a434cb8461a703f299
Issue-ID: DCAEGEN2-306
Signed-off-by: Snigdha Sucharita Patra <sp00503415@techmahindra.com>
// TODO: When putting together the components fail. Should this be a 500 case?
// For now, this is just logged as a warning.
- if (COMPONENT_SOURCE_DCAE_CONTROLLER.equals(sco.getComponentSource().toUpperCase(Locale.ENGLISH))) {
+ if (COMPONENT_SOURCE_DCAE_CONTROLLER.equalsIgnoreCase(sco.getComponentSource())) {
if (this.dcaeControllerClient != null) {
try {
DCAEControllerClient.ServiceInstance serviceInstance