From 38a8ea73937a926f0a057b1682ac7597512eaf38 Mon Sep 17 00:00:00 2001 From: yamanq Date: Wed, 20 Apr 2016 21:06:21 -0400 Subject: [PATCH] bug fix --- atoms/js/onload.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/atoms/js/onload.js b/atoms/js/onload.js index 5a8ee4b..29458af 100644 --- a/atoms/js/onload.js +++ b/atoms/js/onload.js @@ -134,7 +134,12 @@ function createGradientLegend() { var title = document.createElement("h1"); title.className = "tabletitle"; - title.innerHTML = choicesDisplay[1][index] + " (" + units[index] + ")"; + if (units[index] != "") { + var end = choicesDisplay[1][index] + " (" + units[index] + ")"; + } else { + var end = choicesDisplay[1][index]; + } + title.innerHTML = end; get("titleholder").appendChild(title); }