Minor fixes for MangaPlus extension (#3534)
* Minor fixes for MangaPlus extension. * Change the id overriding to the factory. * Remove unnecessary id overriding. * Remove outdated comment.
This commit is contained in:
parent
e5a55452d2
commit
d9309d4b08
|
@ -6,7 +6,7 @@ ext {
|
|||
appName = 'Tachiyomi: MANGA Plus by SHUEISHA'
|
||||
pkgNameSuffix = 'all.mangaplus'
|
||||
extClass = '.MangaPlusFactory'
|
||||
extVersionCode = 8
|
||||
extVersionCode = 9
|
||||
libVersion = '1.2'
|
||||
}
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ abstract class MangaPlus(
|
|||
private val langCode: Language
|
||||
) : HttpSource(), ConfigurableSource {
|
||||
|
||||
override val name = "Manga Plus by Shueisha"
|
||||
override val name = "MANGA Plus by SHUEISHA"
|
||||
|
||||
override val baseUrl = "https://mangaplus.shueisha.co.jp"
|
||||
|
||||
|
@ -196,8 +196,8 @@ abstract class MangaPlus(
|
|||
val isCompleted = details.nonAppearanceInfo.contains(COMPLETE_REGEX)
|
||||
|
||||
return SManga.create().apply {
|
||||
author = title.author
|
||||
artist = title.author
|
||||
author = title.author.replace(" / ", ", ")
|
||||
artist = author
|
||||
description = details.overview + "\n\n" + details.viewingPeriodDescription
|
||||
status = if (isCompleted) SManga.COMPLETED else SManga.ONGOING
|
||||
thumbnail_url = title.portraitImageUrl.toWeservUrl()
|
||||
|
|
|
@ -76,7 +76,7 @@ data class Title(
|
|||
@ProtoId(3) val author: String,
|
||||
@ProtoId(4) val portraitImageUrl: String,
|
||||
@ProtoId(5) val landscapeImageUrl: String,
|
||||
@ProtoId(6) val viewCount: Int,
|
||||
@ProtoId(6) val viewCount: Int = 0,
|
||||
@ProtoId(7) val language: Language? = Language.ENGLISH
|
||||
)
|
||||
|
||||
|
@ -189,6 +189,7 @@ const val DECODE_SCRIPT: String = """
|
|||
.add(new Field("nextTimeStamp", 5, "uint32"))
|
||||
.add(new Field("updateTiming", 6, "UpdateTiming"))
|
||||
.add(new Field("viewingPeriodDescription", 7, "string"))
|
||||
.add(new Field("nonAppearanceInfo", 8, "string", {"default": ""}))
|
||||
.add(new Field("firstChapterList", 9, "Chapter", "repeated"))
|
||||
.add(new Field("lastChapterList", 10, "Chapter", "repeated"))
|
||||
.add(new Field("isSimulReleased", 14, "bool"))
|
||||
|
@ -214,7 +215,7 @@ const val DECODE_SCRIPT: String = """
|
|||
.add(new Field("author", 3, "string"))
|
||||
.add(new Field("portraitImageUrl", 4, "string"))
|
||||
.add(new Field("landscapeImageUrl", 5, "string"))
|
||||
.add(new Field("viewCount", 6, "uint32"))
|
||||
.add(new Field("viewCount", 6, "uint32", {"default": 0}))
|
||||
.add(new Field("language", 7, "Language", {"default": 0}));
|
||||
|
||||
var Language = new Enum("Language")
|
||||
|
|
Loading…
Reference in New Issue