summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2017-02-26 14:14:54 +0300
committerAndrew Dolgov <[email protected]>2017-02-26 14:14:54 +0300
commitb8c68ed431e55ac8ceea1046dd7af94495b1ac90 (patch)
tree69b996fd6d938c9661675cb4450e568465e8fd02
parent575f13609fceeb7ddb599787bef0e83342de8391 (diff)
fix books wrongly displayed as read in offline mode
-rw-r--r--js/offline.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/js/offline.js b/js/offline.js
index 7815b83..8846e8a 100644
--- a/js/offline.js
+++ b/js/offline.js
@@ -32,7 +32,7 @@ function populate_list() {
if (lastread) {
in_progress = lastread.page > 0;
- is_read = lastread.total - lastread.page < 5;
+ is_read = lastread.total > 0 && lastread.total - lastread.page < 5;
}
var cell = "<div class='col-xs-6 col-sm-3 col-md-2 index_cell'>";