MadTheme: add rate limit (1/2) (#10700)

This commit is contained in:
Vetle Ledaal 2022-02-04 19:17:05 +00:00 committed by GitHub
parent acc06d0133
commit b1f6d28cc1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
20 changed files with 347 additions and 1 deletions

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class BeeHentai : MadTheme(
"BeeHentai",
"https://beehentai.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class BoxManhwa : MadTheme(
"BoxManhwa",
"https://boxmanhwa.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,4 @@
dependencies {
implementation project(':lib-ratelimit')
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaBuddy : MadTheme(
"MangaBuddy",
"https://mangabuddy.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = super.client.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaCute : MadTheme(
"MangaCute",
"https://mangacute.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaFab : MadTheme(
"MangaFab",
"https://mangafab.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaForest : MadTheme(
"MangaForest",
"https://mangaforest.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaMad : MadTheme(
"MangaMad",
"https://mangamad.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaMax : MadTheme(
"MangaMax",
"https://mangamax.net",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaSaga : MadTheme(
"MangaSaga",
"https://mangasaga.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaSpin : MadTheme(
"MangaSpin",
"https://mangaspin.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class MangaXYZ : MadTheme(
"MangaXYZ",
"https://mangaxyz.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class ManhuaNow : MadTheme(
"ManhuaNow",
"https://manhuanow.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class ManhuaSite : MadTheme(
"ManhuaSite",
"https://manhuasite.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class TooniClub : MadTheme(
"TooniClub",
"https://tooniclub.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class TooniFab : MadTheme(
"TooniFab",
"https://toonifab.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class ToonilyMe : MadTheme(
"Toonily.me",
"https://toonily.me",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class TooniTube : MadTheme(
"TooniTube",
"https://toonitube.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -0,0 +1,19 @@
package eu.kanade.tachiyomi.extension.en.madtheme
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
import eu.kanade.tachiyomi.multisrc.madtheme.MadTheme
import okhttp3.OkHttpClient
import java.text.SimpleDateFormat
import java.util.Locale
import java.util.concurrent.TimeUnit
class TrueManga : MadTheme(
"TrueManga",
"https://truemanga.com",
"en",
SimpleDateFormat("MMM dd, yyy", Locale.US)
) {
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
.addInterceptor(RateLimitInterceptor(1, 2, TimeUnit.SECONDS))
.build()
}

View File

@ -9,7 +9,7 @@ class MadThemeGenerator : ThemeSourceGenerator {
override val themeClass = "MadTheme" override val themeClass = "MadTheme"
override val baseVersionCode: Int = 2 override val baseVersionCode: Int = 3
override val sources = listOf( override val sources = listOf(
SingleLang("BeeHentai", "https://beehentai.com", "en", isNsfw = true), SingleLang("BeeHentai", "https://beehentai.com", "en", isNsfw = true),