List<String> queries = new ArrayList<String>();
queries.add(query);
FileParse fp = getSequenceReader(queries);
+ if (fp == null || !fp.isValid())
+ {
+ return null;
+ }
FeaturesFile fr = new FeaturesFile(fp);
return new Alignment(fr.getSeqsAsArray());
}
EnsemblFeatureType[] features = getFeaturesToFetch();
AlignmentI geneFeatures = gffFetcher.getSequenceRecords(accId,
features);
- if (geneFeatures.getHeight() > 0)
+ if (geneFeatures != null && geneFeatures.getHeight() > 0)
{
genomicSequence = geneFeatures.getSequenceAt(0);
}