From 145c060c305b9126f1d64978686b5faca75e65b4 Mon Sep 17 00:00:00 2001 From: jprocter Date: Mon, 15 Dec 2008 10:34:19 +0000 Subject: [PATCH] temporary fix and note about null feature group mucking up selection of features to be sorted on --- src/jalview/analysis/AlignmentSorter.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/jalview/analysis/AlignmentSorter.java b/src/jalview/analysis/AlignmentSorter.java index cf5a57a..ab1e62d 100755 --- a/src/jalview/analysis/AlignmentSorter.java +++ b/src/jalview/analysis/AlignmentSorter.java @@ -718,9 +718,10 @@ public class AlignmentSorter || // or ignore based on selection criteria (featureLabels != null && !AlignmentSorter.containsIgnoreCase(sf[f].type, featureLabels)) - || (groupLabels != null - && (sf[f].getFeatureGroup() == null - || !AlignmentSorter.containsIgnoreCase(sf[f].getFeatureGroup(), groupLabels)))) + || (groupLabels != null + // problem here: we cannot eliminate null feature group features + && (sf[f].getFeatureGroup() != null + && !AlignmentSorter.containsIgnoreCase(sf[f].getFeatureGroup(), groupLabels)))) { // forget about this feature sf[f] = null; -- 1.7.10.2