From 378c4867b6a4a4179919b979d044633002bf61da Mon Sep 17 00:00:00 2001 From: Alissa Bonas Date: Wed, 25 Dec 2013 17:29:30 +0200 Subject: [PATCH] Remove redundant expression true:false The expression that is evaluated already returns boolean, no need for additional 'true:false' decision, the correct value is already returned. Change-Id: I48378e88f30a4d9ebd8b9a56b287fb6d9536ec46 Signed-off-by: Alissa Bonas --- .../controller/forwardingrulesmanager/FlowEntry.java | 2 +- .../controller/northbound/integrationtest/NorthboundIT.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/FlowEntry.java b/opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/FlowEntry.java index 83106a391c..d9a0891c2a 100644 --- a/opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/FlowEntry.java +++ b/opendaylight/forwardingrulesmanager/api/src/main/java/org/opendaylight/controller/forwardingrulesmanager/FlowEntry.java @@ -122,7 +122,7 @@ public class FlowEntry implements Cloneable, Serializable { } if (flow == null) { - return (other.flow == null) ? true : false; + return other.flow == null; } else if (other.flow == null) { return false; } diff --git a/opendaylight/northbound/integrationtest/src/test/java/org/opendaylight/controller/northbound/integrationtest/NorthboundIT.java b/opendaylight/northbound/integrationtest/src/test/java/org/opendaylight/controller/northbound/integrationtest/NorthboundIT.java index 602de9a1c6..322f1401ba 100644 --- a/opendaylight/northbound/integrationtest/src/test/java/org/opendaylight/controller/northbound/integrationtest/NorthboundIT.java +++ b/opendaylight/northbound/integrationtest/src/test/java/org/opendaylight/controller/northbound/integrationtest/NorthboundIT.java @@ -1128,7 +1128,7 @@ public class NorthboundIT { } else { JSONObject ja = json.getJSONObject("hostConfig"); String na = ja.getString("networkAddress"); - return (na.equalsIgnoreCase(hostIp)) ? true : false; + return na.equalsIgnoreCase(hostIp); } } -- 2.36.6