[RU]NewManga fix error ImgDto (#13625)

* [RU]NewManga fix error ImgDto

* readable dto
This commit is contained in:
Yjin 2022-09-29 22:16:36 +05:00 committed by GitHub
parent c72a027702
commit 8553e161bc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 12 deletions

View File

@ -6,7 +6,7 @@ ext {
extName = 'NewManga(Newbie)'
pkgNameSuffix = 'ru.newbie'
extClass = '.Newbie'
extVersionCode = 12
extVersionCode = 13
}
dependencies {

View File

@ -103,9 +103,7 @@ class Newbie : ConfigurableSource, HttpSource() {
// Do not change the title name to ensure work with a multilingual catalog!
title = if (isEng.equals("rus")) o.title.ru else o.title.en
url = "$id"
thumbnail_url = if (image.srcset.large.isNotEmpty()) {
"$IMAGE_URL/${image.srcset.large}"
} else "$IMAGE_URL/${image.srcset.small}"
thumbnail_url = "$IMAGE_URL/${image.name}"
}
}
@ -254,7 +252,7 @@ class Newbie : ConfigurableSource, HttpSource() {
// Do not change the title name to ensure work with a multilingual catalog!
title = if (isEng.equals("rus")) o.title.ru else o.title.en
url = "$id"
thumbnail_url = "$IMAGE_URL/${image.srcset.large}"
thumbnail_url = "$IMAGE_URL/${image.name}"
author = o.author?.name
artist = o.artist?.name
val mediaNameLanguage = if (isEng.equals("rus")) o.title.en else o.title.ru

View File

@ -44,13 +44,7 @@ data class AuthorDto(
@Serializable
data class ImgDto(
val srcset: ImgsDto,
)
@Serializable
data class ImgsDto(
val large: String,
val small: String,
val name: String,
)
@Serializable