diff --git a/src/en/mangarock/build.gradle b/src/en/mangarock/build.gradle index 9c08853ac..9c8774ad6 100644 --- a/src/en/mangarock/build.gradle +++ b/src/en/mangarock/build.gradle @@ -5,7 +5,7 @@ ext { appName = 'Tachiyomi: Manga Rock' pkgNameSuffix = 'en.mangarock' extClass = '.MangaRock' - extVersionCode = 12 + extVersionCode = 13 libVersion = '1.2' } diff --git a/src/en/mangarock/src/eu/kanade/tachiyomi/extension/en/mangarock/MangaRock.kt b/src/en/mangarock/src/eu/kanade/tachiyomi/extension/en/mangarock/MangaRock.kt index 4765068e5..daf124841 100644 --- a/src/en/mangarock/src/eu/kanade/tachiyomi/extension/en/mangarock/MangaRock.kt +++ b/src/en/mangarock/src/eu/kanade/tachiyomi/extension/en/mangarock/MangaRock.kt @@ -12,12 +12,7 @@ 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.HttpSource -import okhttp3.MediaType -import okhttp3.OkHttpClient -import okhttp3.Request -import okhttp3.RequestBody -import okhttp3.Response -import okhttp3.ResponseBody +import okhttp3.* import org.json.JSONObject import rx.Observable import java.util.ArrayList @@ -40,6 +35,9 @@ class MangaRock : HttpSource() { override val supportsLatest = true + override fun headersBuilder(): Headers.Builder = Headers.Builder() + .add("Origin", "https://mangarock.com") + // Handles the page decoding override val client: OkHttpClient = super.client.newBuilder().addInterceptor(fun(chain): Response { val url = chain.request().url().toString()