Fixed the book reader off by one issue with loading last page (#911)

This commit is contained in:
Joseph Milazzo 2022-01-08 07:32:56 -08:00 committed by GitHub
parent 2bd35b33ad
commit bb978484db
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -812,7 +812,7 @@ export class BookReaderComponent implements OnInit, AfterViewInit, OnDestroy {
this.setPageNum(this.pageNum - 1); this.setPageNum(this.pageNum - 1);
} }
if (this.pageNum >= this.maxPages - 1) { if (this.pageNum === this.maxPages - 1) {
// Move to next volume/chapter automatically // Move to next volume/chapter automatically
this.loadNextChapter(); this.loadNextChapter();
} }