From f4778f6fdc3c5f2011ff7c3cb877c93e9d288f9b Mon Sep 17 00:00:00 2001 From: hexated Date: Wed, 2 Nov 2022 06:44:15 +0700 Subject: [PATCH] fixed DramaidProvider sources --- .../src/main/kotlin/com/hexated/DramaidProvider.kt | 14 +++++++++++++- .../kotlin/com/hexated/DramaidProviderPlugin.kt | 1 + 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/DramaidProvider/src/main/kotlin/com/hexated/DramaidProvider.kt b/DramaidProvider/src/main/kotlin/com/hexated/DramaidProvider.kt index 5c6ed8c7..1d62d7d7 100644 --- a/DramaidProvider/src/main/kotlin/com/hexated/DramaidProvider.kt +++ b/DramaidProvider/src/main/kotlin/com/hexated/DramaidProvider.kt @@ -2,6 +2,7 @@ package com.hexated import com.fasterxml.jackson.annotation.JsonProperty import com.lagradost.cloudstream3.* +import com.lagradost.cloudstream3.extractors.XStreamCdn import com.lagradost.cloudstream3.utils.AppUtils.tryParseJson import com.lagradost.cloudstream3.utils.ExtractorLink import com.lagradost.cloudstream3.utils.getQualityFromName @@ -202,7 +203,12 @@ class DramaidProvider : MainAPI() { it.replace("https://ndrama.xyz", "https://www.fembed.com") }.apmap { when { - it.contains("motonews.club") -> invokeDriveSource(it, this.name, subtitleCallback, callback) + it.contains("motonews.club") -> invokeDriveSource( + it, + this.name, + subtitleCallback, + callback + ) else -> loadExtractor(it, data, subtitleCallback, callback) } } @@ -211,3 +217,9 @@ class DramaidProvider : MainAPI() { } } + +class Vanfem : XStreamCdn() { + override val name: String = "Vanfem" + override val mainUrl: String = "https://vanfem.com" +} + diff --git a/DramaidProvider/src/main/kotlin/com/hexated/DramaidProviderPlugin.kt b/DramaidProvider/src/main/kotlin/com/hexated/DramaidProviderPlugin.kt index 25753bb4..78c28ae2 100644 --- a/DramaidProvider/src/main/kotlin/com/hexated/DramaidProviderPlugin.kt +++ b/DramaidProvider/src/main/kotlin/com/hexated/DramaidProviderPlugin.kt @@ -10,5 +10,6 @@ class DramaidProviderPlugin: Plugin() { override fun load(context: Context) { // All providers should be added in this manner. Please don't edit the providers list directly. registerMainAPI(DramaidProvider()) + registerExtractorAPI(Vanfem()) } } \ No newline at end of file