Check hiddenSequence before placing in tmp
authoramwaterhouse <Andrew Waterhouse>
Wed, 25 Oct 2006 14:57:02 +0000 (14:57 +0000)
committeramwaterhouse <Andrew Waterhouse>
Wed, 25 Oct 2006 14:57:02 +0000 (14:57 +0000)
src/jalview/datamodel/HiddenSequences.java

index 17a6c11..9a4e7c6 100755 (executable)
@@ -75,8 +75,8 @@ public class HiddenSequences
     {\r
       if (i > deletionIndex)\r
         tmp[i-1] = hiddenSequences[i];\r
-      else\r
-        tmp[i] = hiddenSequences[i];\r
+      else if(hiddenSequences[i]!=null)\r
+       tmp[i] = hiddenSequences[i];\r
     }\r
 \r
    hiddenSequences = tmp;\r
@@ -111,7 +111,7 @@ public class HiddenSequences
     alignmentIndex = adjustForHiddenSeqs(alignmentIndex);\r
 \r
     if(hiddenSequences[alignmentIndex]!=null)\r
-    System.out.println("ERROR!!!!!!!!!!!");\r
+      System.out.println("ERROR!!!!!!!!!!!");\r
 \r
     hiddenSequences[alignmentIndex] = sequence;\r
 \r