summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2014-01-31 20:59:43 +0000
committerJo-Philipp Wich <jow@openwrt.org>2014-01-31 20:59:43 +0000
commit7dc42e1f9fd2ecff97be4beeb8345e195eb6e74b (patch)
treeffe427282e3a4fc64ea96fe204eaf1a0c1a86c06
parentf9ab0f915f41fab8031f0b44168df1b0fddae961 (diff)
downloadluci2-ui-7dc42e1f9fd2ecff97be4beeb8345e195eb6e74b.tar.gz
luci2: properly handle empty hash info, fixes endless loop with expired sids
-rw-r--r--luci2/htdocs/luci2/luci2.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/luci2/htdocs/luci2/luci2.js b/luci2/htdocs/luci2/luci2.js
index ab7faa8..6a41e26 100644
--- a/luci2/htdocs/luci2/luci2.js
+++ b/luci2/htdocs/luci2/luci2.js
@@ -364,8 +364,10 @@ function LuCI2()
h += keys[i] + ':' + data[keys[i]];
}
- if (h)
+ if (h.length)
location.hash = '#' + h;
+ else
+ location.hash = '';
};
this.getHash = function(key)