From 7a8302bb7a4a18121f8aa3de49486c02d453bbda Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Fri, 5 Jul 2013 17:13:37 +0100 Subject: [PATCH] Protect hiding/showing of targets. --- experiments/spclient/mkws.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/experiments/spclient/mkws.js b/experiments/spclient/mkws.js index 8c856f2..be9f10a 100644 --- a/experiments/spclient/mkws.js +++ b/experiments/spclient/mkws.js @@ -403,17 +403,17 @@ function switchView(view) { switch(view) { case 'targets': - targets.style.display = "block"; + if (targets) targets.style.display = "block"; if (results) results.style.display = "none"; if (blanket) { blanket.style.display = "none"; } break; case 'results': - targets.style.display = "none"; + if (targets) targets.style.display = "none"; if (results) results.style.display = "block"; if (blanket) { blanket.style.display = "block"; } break; case 'none': - targets.style.display = "none"; + if (targets) targets.style.display = "none"; if (results) results.style.display = "none"; if (blanket) { blanket.style.display = "none"; } break; -- 1.7.10.4