Future-Proofing Chapters and Pages Local Storage indexes.

Closes #1289 .
This commit is contained in:
TheBest_F-22!.
2025-02-16 07:22:44 +00:00
committed by GitHub
parent 8a26587250
commit be455bc897
3 changed files with 3 additions and 3 deletions

View File

@@ -107,7 +107,7 @@ class MangaIndex(source: String?) {
jo.put("uploadDate", chapter.value.uploadDate)
jo.put("scanlator", chapter.value.scanlator)
jo.put("branch", chapter.value.branch)
jo.put("entries", "%08d_%03d\\d{3}".format(chapter.value.branch.hashCode(), chapter.index + 1))
jo.put("entries", "%08d_%04d\\d{4}".format(chapter.value.branch.hashCode(), chapter.index + 1))
jo.put("file", filename)
chapters.put(chapter.value.id.toString(), jo)
}

View File

@@ -160,6 +160,6 @@ class LocalMangaDirOutput(
companion object {
private const val FILENAME_PATTERN = "%08d_%03d%03d"
private const val FILENAME_PATTERN = "%08d_%04d%04d"
}
}

View File

@@ -116,7 +116,7 @@ class LocalMangaZipOutput(
companion object {
private const val FILENAME_PATTERN = "%08d_%03d%03d"
private const val FILENAME_PATTERN = "%08d_%04d%04d"
suspend fun filterChapters(file: File, manga: Manga, idsToRemove: Set<Long>) =
runInterruptible(Dispatchers.IO) {