return;
}
List<DBRefEntry> selfs = new ArrayList<DBRefEntry>();
- selfs.addAll(Arrays.asList(selectDbRefs(!sequence.isProtein(),
- sequence.getDBRefs())));
+ {
+ DBRefEntry[] selfArray = selectDbRefs(!sequence.isProtein(),
+ sequence.getDBRefs());
+ if (selfArray == null || selfArray.length == 0)
+ {
+ // nothing to do
+ return;
+ }
+ selfs.addAll(Arrays.asList(selfArray));
+ }
// filter non-primary refs
for (DBRefEntry p : pr)