Correctly check if reader chapter exists
As explained in c70287363a8e9308fc294baf83c5656a21a479b1, the "chapterSourceOrder" does not start at 0, thus, in case it's the last known chapter, "doesChapterExist" was always false due to subtracting 1 of the total chapters
This commit is contained in:
@@ -163,7 +163,7 @@ const BaseReader = ({
|
|||||||
!chaptersResponse.loading &&
|
!chaptersResponse.loading &&
|
||||||
!chaptersResponse.error &&
|
!chaptersResponse.error &&
|
||||||
chapterSourceOrder >= 0 &&
|
chapterSourceOrder >= 0 &&
|
||||||
chapterSourceOrder <= chapters.length - 1;
|
chapterSourceOrder <= chapters.length;
|
||||||
|
|
||||||
const isLoading =
|
const isLoading =
|
||||||
!areSettingsSet ||
|
!areSettingsSet ||
|
||||||
|
|||||||
Reference in New Issue
Block a user