bugfix:
when the bookmark list is empty, the script tried eternally to load more bookmarks. resolved by introducing a check
This commit is contained in:
@@ -55,8 +55,8 @@
|
|||||||
bookmarks = Object.values(merged).sort((a, b) => new Date(b.timestamp) - new Date(a.timestamp));
|
bookmarks = Object.values(merged).sort((a, b) => new Date(b.timestamp) - new Date(a.timestamp));
|
||||||
loader.offset += loader.limit;
|
loader.offset += loader.limit;
|
||||||
loader.active = false;
|
loader.active = false;
|
||||||
error = false;
|
error = null;
|
||||||
onscroll(null);
|
if (Object.keys(raw).length) onscroll(null); // when bookmarks were received, check whether they fill up the page
|
||||||
} else {
|
} else {
|
||||||
error = await resp.html();
|
error = await resp.html();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user