MangaZuki: return empty list for search (fixes #1034) (#1046)

This commit is contained in:
Eugene 2019-04-21 11:31:12 -04:00 committed by GitHub
parent 02908dfdf7
commit 5533dae52f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 14 additions and 9 deletions

View File

@ -5,7 +5,7 @@ ext {
appName = 'Tachiyomi: Mangazuki'
pkgNameSuffix = 'en.mangazuki'
extClass = '.Mangazuki'
extVersionCode = 4
extVersionCode = 5
libVersion = '1.0'
}

View File

@ -1,16 +1,21 @@
package eu.kanade.tachiyomi.extension.en.mangazuki
import eu.kanade.tachiyomi.network.GET
import eu.kanade.tachiyomi.source.model.*
import eu.kanade.tachiyomi.source.model.FilterList
import eu.kanade.tachiyomi.source.model.MangasPage
import eu.kanade.tachiyomi.source.model.Page
import eu.kanade.tachiyomi.source.model.SChapter
import eu.kanade.tachiyomi.source.model.SManga
import eu.kanade.tachiyomi.source.online.ParsedHttpSource
import okhttp3.HttpUrl
import okhttp3.Request
import org.jsoup.nodes.Document
import org.jsoup.nodes.Element
import org.jsoup.select.Elements
import rx.Observable
import java.text.ParseException
import java.text.SimpleDateFormat
import java.util.*
import java.util.Date
import java.util.Locale
class Mangazuki : ParsedHttpSource() {
@ -58,12 +63,12 @@ class Mangazuki : ParsedHttpSource() {
override fun latestUpdatesNextPageSelector() = popularMangaNextPageSelector()
// Search doesn't work on the site
override fun fetchSearchManga(page: Int, query: String, filters: FilterList): Observable<MangasPage> = Observable.empty()
override fun searchMangaRequest(page: Int, query: String, filters: FilterList): Request = throw Exception("Not used")
override fun searchMangaSelector() = throw Exception("Not used")
override fun searchMangaFromElement(element: Element): SManga = throw Exception("Not used")
override fun searchMangaNextPageSelector() = throw Exception("Not used")
override fun mangaDetailsParse(document: Document): SManga {

View File

@ -32,7 +32,7 @@ class QuestionableContent : ParsedHttpSource() {
return Observable.just(MangasPage(arrayListOf(manga), false))
}
override fun fetchSearchManga(page: Int, query: String, filters: FilterList) = Observable.just(MangasPage(arrayListOf(), false))
override fun fetchSearchManga(page: Int, query: String, filters: FilterList): Observable<MangasPage> = Observable.empty()
override fun fetchMangaDetails(manga: SManga) = Observable.just(manga)

View File

@ -37,7 +37,7 @@ class Xkcd : ParsedHttpSource() {
return Observable.just(MangasPage(arrayListOf(manga), false))
}
override fun fetchSearchManga(page: Int, query: String, filters: FilterList) = Observable.just(MangasPage(arrayListOf(), false))
override fun fetchSearchManga(page: Int, query: String, filters: FilterList): Observable<MangasPage> = Observable.empty()
override fun fetchMangaDetails(manga: SManga): Observable<SManga> {
return Observable.just(manga)