mirror of
https://github.com/Suwayomi/Suwayomi-Server.git
synced 2026-07-10 06:14:35 -05:00
OPDS: Offer CBZ in older mimetype (#1731)
* OPDS: Offer CBZ in older mimetype * OPDS: Include length when offering CBZ download * Disable compression on CBZ endpoint Zipping a zip * CBZ download match content type of OPDS * Move compression disable * Introduce setting for configuring CBZ mimetype * Document new option [no-ci] * Update server/src/main/kotlin/suwayomi/tachidesk/opds/impl/OpdsEntryBuilder.kt Co-authored-by: Mitchell Syer <Syer10@users.noreply.github.com> --------- Co-authored-by: Mitchell Syer <Syer10@users.noreply.github.com>
This commit is contained in:
@@ -100,12 +100,11 @@ object ChapterDownloadHelper {
|
||||
return Triple(cbzFile.first, fileName, cbzFile.second)
|
||||
}
|
||||
|
||||
fun getCbzMetadataForDownload(chapterId: Int): Triple<String, Long, String> { // fileName, fileSize, contentType
|
||||
fun getCbzMetadataForDownload(chapterId: Int): Pair<String, Long> { // fileName, fileSize
|
||||
val (chapterData, fileName) = getChapterWithCbzFileName(chapterId)
|
||||
|
||||
val fileSize = provider(chapterData.mangaId, chapterData.id).getArchiveSize()
|
||||
val contentType = "application/vnd.comicbook+zip"
|
||||
|
||||
return Triple(fileName, fileSize, contentType)
|
||||
return Pair(fileName, fileSize)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user