diff --git a/src/ru/mangahub/res/mipmap-hdpi/ic_launcher.png b/src/ru/mangahub/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 000000000..de61c1bdd Binary files /dev/null and b/src/ru/mangahub/res/mipmap-hdpi/ic_launcher.png differ diff --git a/src/ru/mangahub/res/mipmap-mdpi/ic_launcher.png b/src/ru/mangahub/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 000000000..951e69ca7 Binary files /dev/null and b/src/ru/mangahub/res/mipmap-mdpi/ic_launcher.png differ diff --git a/src/ru/mangahub/res/mipmap-xhdpi/ic_launcher.png b/src/ru/mangahub/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 000000000..a0b366173 Binary files /dev/null and b/src/ru/mangahub/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/src/ru/mangahub/res/mipmap-xxhdpi/ic_launcher.png b/src/ru/mangahub/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 000000000..fda0c342a Binary files /dev/null and b/src/ru/mangahub/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/src/ru/mangahub/res/mipmap-xxxhdpi/ic_launcher.png b/src/ru/mangahub/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 000000000..45a4c520c Binary files /dev/null and b/src/ru/mangahub/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/src/ru/mangahub/src/eu/kanade/tachiyomi/extension/ru/mangahub/Mangahub.kt b/src/ru/mangahub/src/eu/kanade/tachiyomi/extension/ru/mangahub/Mangahub.kt index 41773018b..5c8f58e9d 100644 --- a/src/ru/mangahub/src/eu/kanade/tachiyomi/extension/ru/mangahub/Mangahub.kt +++ b/src/ru/mangahub/src/eu/kanade/tachiyomi/extension/ru/mangahub/Mangahub.kt @@ -21,10 +21,10 @@ open class Mangahub : ParsedHttpSource() { override val supportsLatest = true override fun popularMangaRequest(page: Int): Request = - GET("$baseUrl/explore?search%5Bsort%5D=rating&search%5BdateStart%5D%5Bleft_number%5D=1972&search%5BdateStart%5D%5Bright_number%5D=2018&page=${page + 1}", headers) + GET("$baseUrl/explore?search[sort]=rating&search[dateStart][left_number]=1972&search[dateStart][right_number]=2018&page=${page + 1}", headers) override fun latestUpdatesRequest(page: Int): Request = - GET("$baseUrl/explore?search%5Bsort%5D=update&search%5BdateStart%5D%5Bleft_number%5D=1972&search%5BdateStart%5D%5Bright_number%5D=2018&page=${page + 1}", headers) + GET("$baseUrl/explore?search[sort]=update&search[dateStart][left_number]=1972&search[dateStart][right_number]=2018&page=${page + 1}", headers) override fun popularMangaSelector() = "div.list-element" @@ -57,7 +57,7 @@ open class Mangahub : ParsedHttpSource() { override fun mangaDetailsParse(document: Document): SManga { val manga = SManga.create() - manga.author = if(document.select("[itemprop=\"author\"]") != null) document.select("[itemprop=\"author\"]").text() + manga.author = document.select("[itemprop=\"author\"]")?.text() manga.genre = document.select("div.b-dtl-desc__labels")[0].text().replace(" ", ", ") manga.description = if (document.select("div.b-dtl-desc__desc-info > p").last() != null) document.select("div.b-dtl-desc__desc-info > p").last().text() else null manga.status = parseStatus(document) @@ -102,10 +102,8 @@ open class Mangahub : ParsedHttpSource() { val pictures = document.select("div.b-reader.b-reader__full").attr("data-js-scans").replace(""", "\"").replace("\\/", "/") val r = Regex("""\/\/([\w\.\/])+""") val pages = mutableListOf() - var index = 0 - r.findAll(pictures).forEach { - pages.add(Page(index=index, imageUrl="http:${it.value}")) - index++ + for((index, value) in r.findAll(pictures).withIndex()) { + pages.add(Page(index=index, imageUrl="http:${value.value}")) } return pages