diff options
Diffstat (limited to 'yang-comparator/src')
-rw-r--r-- | yang-comparator/src/main/java/org/onap/modeling/yangkit/comparator/CommonYangStatementComparator.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/yang-comparator/src/main/java/org/onap/modeling/yangkit/comparator/CommonYangStatementComparator.java b/yang-comparator/src/main/java/org/onap/modeling/yangkit/comparator/CommonYangStatementComparator.java index 8b03304..8be269e 100644 --- a/yang-comparator/src/main/java/org/onap/modeling/yangkit/comparator/CommonYangStatementComparator.java +++ b/yang-comparator/src/main/java/org/onap/modeling/yangkit/comparator/CommonYangStatementComparator.java @@ -370,6 +370,12 @@ public class CommonYangStatementComparator<T extends YangStatement> extends Abst * @return true or false */ public static boolean yangStatementIsEqual(YangStatement left, YangStatement right) { + if ((null == left) || (null == right)) { + if ((null == left) && (null == right)) { + return true; + } + return false; + } if ((left instanceof SchemaNode) && (right instanceof SchemaNode)) { SchemaNode leftSchemaNode = (SchemaNode) left; SchemaNode rightSchemaNode = (SchemaNode) right; |