journal-gateway: use localStorage["cursor"] only when it has valid value
Discovered by LGTM.
This commit is contained in:
parent
c497e449f4
commit
944072fedd
|
@ -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";
|
||||
|
||||
|
|
Loading…
Reference in a new issue