From b45d69ef2de24a3b32990f7489adf269903bb4c3 Mon Sep 17 00:00:00 2001 From: Olivier Date: Tue, 11 Oct 2022 23:43:54 +0900 Subject: [PATCH] set currentImage to the start if no bookmark --- cps/templates/readcbr.html | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cps/templates/readcbr.html b/cps/templates/readcbr.html index 6ab14a94..3d0ccab1 100644 --- a/cps/templates/readcbr.html +++ b/cps/templates/readcbr.html @@ -205,7 +205,10 @@ useBookmarks: "{{ g.user.is_authenticated | tojson }}" }; if (calibre.useBookmarks) { - currentImage = eval(calibre.bookmark) + currentImage = eval(calibre.bookmark); + if (typeof currentImage !== 'number'){ + currentImage = 0; + } } document.onreadystatechange = function () {