Merge commit
[jalview.git] / src / jalview / datamodel / Mapping.java
index 59dc8ff..559ae4c 100644 (file)
@@ -348,6 +348,8 @@ public class Mapping
   @Override
   public boolean equals(Object o)
   {
+    // TODO should override Object.hashCode() to ensure that equal objects have
+    // equal hashcodes
     if (o == null || !(o instanceof Mapping))
     {
       return false;
@@ -366,7 +368,7 @@ public class Mapping
     {
       return false;
     }
-    if (map.equals(other.map))
+    if ((map == null && other.map == null) || map.equals(other.map))
     {
       return true;
     }