Handle ".5" chapters in chapter transition warning

".5" chapters would incorrectly trigger the missing chapter warning
This commit is contained in:
schroda
2024-12-12 12:56:40 +01:00
parent 858c3b4bcf
commit 89b81de830

View File

@@ -192,7 +192,7 @@ export class ReaderControls {
const missingChapters = Math.abs(currentChapter.chapterNumber - chapterToOpen.chapterNumber);
const isSameScanlator = currentChapter.scanlator === chapterToOpen.scanlator;
const isContinuousChapter = missingChapters === 1;
const isContinuousChapter = missingChapters <= 1;
const showWarning = !isSameScanlator || !isContinuousChapter;
if (!showWarning) {