1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-30 06:25:37 +03:00

journal-gateway: use localStorage["cursor"] only when it has valid value

Discovered by LGTM.
This commit is contained in:
Yu Watanabe 2018-06-27 14:50:19 +09:00
parent c497e449f4
commit 944072fedd

View File

@ -236,10 +236,12 @@
function entriesLoad(range) {
if (range == null)
range = localStorage["cursor"] + ":0";
if (range == null)
range = "";
if (range == null) {
if (localStorage["cursor"] != null && localStorage["cursor"] != "")
range = localStorage["cursor"] + ":0";
else
range = "";
}
var url = "/entries";