JAL-2001 catch -ve column values
authorJim Procter <jprocter@issues.jalview.org>
Mon, 4 Apr 2016 15:12:48 +0000 (16:12 +0100)
committerJim Procter <jprocter@issues.jalview.org>
Mon, 4 Apr 2016 15:12:48 +0000 (16:12 +0100)
(fixes failing test jalview.util.MappingUtilsTest.testMapColumnSelection)

src/jalview/datamodel/ColumnSelection.java

index cfe4685..c891485 100644 (file)
@@ -263,7 +263,7 @@ public class ColumnSelection
    */
   public boolean contains(int col)
   {
-    return selected.isSelected(col);
+    return (col > -1) ? selected.isSelected(col) : false;
   }
 
   /**