git://source.jalview.org
/
jalview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1c5971e
)
JAL-2210 patch for when no DBRefs on sequence
author
Jim Procter
<jprocter@issues.jalview.org>
Wed, 28 Sep 2016 14:20:46 +0000
(15:20 +0100)
committer
Jim Procter
<jprocter@issues.jalview.org>
Wed, 28 Sep 2016 14:20:46 +0000
(15:20 +0100)
src/jalview/util/DBRefUtils.java
patch
|
blob
|
history
diff --git
a/src/jalview/util/DBRefUtils.java
b/src/jalview/util/DBRefUtils.java
index
2d09088
..
757fc4d
100755
(executable)
--- a/
src/jalview/util/DBRefUtils.java
+++ b/
src/jalview/util/DBRefUtils.java
@@
-650,8
+650,16
@@
public class DBRefUtils
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)