[HepData-svn] r1895 - trunk/hepdata-webapp/src/main/java/cedar/hepdata/webapp/components

blackhole at projects.hepforge.org blackhole at projects.hepforge.org
Mon Sep 28 21:28:30 BST 2015


Author: watt
Date: Mon Sep 28 21:28:30 2015
New Revision: 1895

Log:
Check for null in DatasetAsHtml

Modified:
   trunk/hepdata-webapp/src/main/java/cedar/hepdata/webapp/components/DatasetAsHtml.java

Modified: trunk/hepdata-webapp/src/main/java/cedar/hepdata/webapp/components/DatasetAsHtml.java
==============================================================================
--- trunk/hepdata-webapp/src/main/java/cedar/hepdata/webapp/components/DatasetAsHtml.java	Mon Sep 28 21:13:24 2015	(r1894)
+++ trunk/hepdata-webapp/src/main/java/cedar/hepdata/webapp/components/DatasetAsHtml.java	Mon Sep 28 21:28:30 2015	(r1895)
@@ -450,9 +450,9 @@
                     if (b != null) {
                         if (b.getDescription() == null){
                             if (b.getRelation() == Relation.EQUALS) {
-                                low = b.getLowValue();
-                                high = b.getHighValue();
-                                f = b.getFocus();
+                                if (b.getLowValue() != null) { low = b.getLowValue(); }
+                                if (b.getHighValue() != null) { high = b.getHighValue(); }
+                                if (b.getFocus() != null) { f = b.getFocus(); }
                                 int lsd = 0;
                                 int msd = 0;                             
                                 if(f != null) {  


More information about the HepData-svn mailing list