aboutsummaryrefslogtreecommitdiffstats
path: root/oom-app-common
diff options
context:
space:
mode:
authorJun Hu <jh245g@att.com>2017-09-22 13:18:37 +0000
committerGerrit Code Review <gerrit@onap.org>2017-09-22 13:18:37 +0000
commit63cdf764c9c574687c8e81338e98f1577c40de2c (patch)
tree6984d049db1056fda61035cb2080767eecb37407 /oom-app-common
parent5633ea611b4c84653d082f0c3c37edcaa74ac641 (diff)
parent4b23fde59f0ddb4802d162f7fa97f2e18d43ffe2 (diff)
Merge "Use isEmpty() to check collection size"
Diffstat (limited to 'oom-app-common')
-rw-r--r--oom-app-common/src/main/java/org/onap/oom/dashboard/controller/HealthCheckController.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/oom-app-common/src/main/java/org/onap/oom/dashboard/controller/HealthCheckController.java b/oom-app-common/src/main/java/org/onap/oom/dashboard/controller/HealthCheckController.java
index fe54790..7ed3fbe 100644
--- a/oom-app-common/src/main/java/org/onap/oom/dashboard/controller/HealthCheckController.java
+++ b/oom-app-common/src/main/java/org/onap/oom/dashboard/controller/HealthCheckController.java
@@ -72,7 +72,7 @@ public class HealthCheckController extends UnRestrictedBaseController {
@SuppressWarnings("unchecked")
// Get the single app.
List<App> list = dataAccessService.getList(App.class, null);
- if (list.size() > 0)
+ if (!list.isEmpty())
healthStatus = new HealthStatus(200, SystemProperties.getProperty(SystemProperties.APP_DISPLAY_NAME) + " health check succeeded");
else
healthStatus = new HealthStatus(500, SystemProperties.getProperty(SystemProperties.APP_DISPLAY_NAME) + " health check failed to run db query");