From: gmungoc Date: Wed, 11 Mar 2015 08:45:01 +0000 (+0000) Subject: JAL-845 handle no profile without NPE! X-Git-Url: http://source.jalview.org/gitweb/?p=jalview.git;a=commitdiff_plain;h=15f308b25f41681924975f6e4c7d564ebe31263e JAL-845 handle no profile without NPE! --- diff --git a/src/jalview/renderer/AnnotationRenderer.java b/src/jalview/renderer/AnnotationRenderer.java index 2e40416..1d1010f 100644 --- a/src/jalview/renderer/AnnotationRenderer.java +++ b/src/jalview/renderer/AnnotationRenderer.java @@ -1335,12 +1335,11 @@ public class AnnotationRenderer */ int profl[] = getProfileFor(_aa, column); - boolean isStructureProfile = profl[0] == AlignmentAnnotation.STRUCTURE_PROFILE; - boolean isCdnaProfile = profl[0] == AlignmentAnnotation.CDNA_PROFILE; - // just try to draw the logo if profl is not null if (profl != null && profl[2] != 0) { + boolean isStructureProfile = profl[0] == AlignmentAnnotation.STRUCTURE_PROFILE; + boolean isCdnaProfile = profl[0] == AlignmentAnnotation.CDNA_PROFILE; float ht = normaliseProfile ? y - _aa.graphHeight : y1; double htn = normaliseProfile ? _aa.graphHeight : (y2 - y1);// aa.graphHeight; double hght;