diff options
author | DeWayne Filppi <dewayne@cloudify.co> | 2018-02-27 15:51:23 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2018-02-27 15:51:23 +0000 |
commit | 5066a084fc0fead2c14fed9885f52dd7980e3492 (patch) | |
tree | 7f52597a89f6ac8cf69a21616220e468ad51ecb8 /adapters/mso-adapter-utils/src/main/java/org/openecomp | |
parent | 40bb7adfbbe26be4e459e269bfd277436deb21cf (diff) | |
parent | 939caf126117d3d3338d38a76c2e67eabaff3bc0 (diff) |
Merge "Make use of getOrDefault"
Diffstat (limited to 'adapters/mso-adapter-utils/src/main/java/org/openecomp')
-rw-r--r-- | adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/beans/StackInfo.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/beans/StackInfo.java b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/beans/StackInfo.java index 600985e310..506b62994d 100644 --- a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/beans/StackInfo.java +++ b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/beans/StackInfo.java @@ -67,10 +67,8 @@ public class StackInfo { if (stack.getStackStatus() == null) { this.status = HeatStatus.INIT; - } else if (heatStatusMap.containsKey(stack.getStackStatus())) { - this.status = heatStatusMap.get(stack.getStackStatus()); } else { - this.status = HeatStatus.UNKNOWN; + this.status = heatStatusMap.getOrDefault(stack.getStackStatus(), HeatStatus.UNKNOWN); } if (stack.getOutputs() != null) { this.outputs = new HashMap<>(); |