Skip to content

Commit

Permalink
Small cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
jakepurple13 committed Nov 29, 2023
1 parent 9452a51 commit c10db51
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 43 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import com.programmersbox.anime_sources.anime.AnimeKisaMovies
import com.programmersbox.anime_sources.anime.AnimeKisaSubbed
import com.programmersbox.anime_sources.anime.CrunchyRoll
import com.programmersbox.anime_sources.anime.Dopebox
import com.programmersbox.anime_sources.anime.GogoAnimeVC
import com.programmersbox.anime_sources.anime.Hdm
import com.programmersbox.anime_sources.anime.PutlockerAnime
import com.programmersbox.anime_sources.anime.PutlockerCartoons
Expand All @@ -27,7 +26,7 @@ enum class Sources(private val api: ApiService, override val notWorking: Boolean

ALLANIME(AllAnime),

GOGOANIME_VC(GogoAnimeVC),
//GOGOANIME_VC(GogoAnimeVC),
HDM(Hdm, true),
//ANIMESIMPLE_SUBBED(AnimeSimpleSubbed), ANIMESIMPLE_DUBBED(AnimeSimpleDubbed),

Expand Down Expand Up @@ -63,7 +62,7 @@ enum class Sources(private val api: ApiService, override val notWorking: Boolean
DOPEBOX,
SFLIX,
WCOSTREAM,
GOGOANIME_VC,
//GOGOANIME_VC,
ANIMEFLICK,
ANIMEKISA_SUBBED,
//HDM,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,32 +1,21 @@
package com.programmersbox.anime_sources.anime

import androidx.compose.ui.util.fastForEach
import androidx.compose.ui.util.fastMap
import com.programmersbox.anime_sources.ShowApi
import com.programmersbox.anime_sources.Sources
import com.programmersbox.anime_sources.toJsoup
import com.programmersbox.anime_sources.utilities.JsUnpacker
import com.programmersbox.anime_sources.utilities.extractors
import com.programmersbox.anime_sources.utilities.fixUrl
import com.programmersbox.anime_sources.utilities.getQualityFromName
import com.programmersbox.models.ChapterModel
import com.programmersbox.models.InfoModel
import com.programmersbox.models.ItemModel
import com.programmersbox.models.Storage
import org.jsoup.Jsoup

/*
object GogoAnimeVC : ShowApi(
baseUrl = "https://gogoanime.sk",
recentPath = "",
allPath = ""
) {
override val serviceName: String get() = "GOGOANIME_VC"

*/
/**
private val headers = mapOf(
"authority" to "ajax.gogo-load.com",
"sec-ch-ua" to "\"Google Chrome\";v=\"89\", \"Chromium\";v=\"89\", \";Not A Brand\";v=\"99\"",
"accept" to "text/html, */*; q=0.01",
"accept" to "text/html, */
/**; q=0.01",
"dnt" to "1",
"sec-ch-ua-mobile" to "?0",
"user-agent" to "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.90 Safari/537.36",
Expand All @@ -36,7 +25,8 @@ object GogoAnimeVC : ShowApi(
"sec-fetch-dest" to "empty",
"referer" to "$baseUrl/"
)

**/
/*
private val parseRegex = Regex("""<li>\s*\n.*\n.*<a\s*href=["'](.*?-episode-(\d+))["']\s*title=["'](.*?)["']>\n.*?img src="(.*?)"""")
override suspend fun recent(page: Int): List<ItemModel> {
Expand Down Expand Up @@ -200,29 +190,7 @@ object GogoAnimeVC : ShowApi(
//println(url + "\t" + e.name)
e.getUrl(url)
} else emptyList()
/*listOf(
Storage(
link = it.attr("href"),
source = link,
filename = "${chapterModel.name}.mp4",
quality = it.text(),
sub = it.text()
)
)*/
}
//.distinctBy { it.link }
/*if(url.startsWith(XStreamCdn.mainUrl))
XStreamCdn.getUrl(url)
else
listOf(
Storage(
link = it.attr("href"),
source = link,
filename = "${chapterModel.name}.mp4",
quality = it.text(),
sub = it.text()
)
)*/
}
}
.flatten()
Expand All @@ -235,5 +203,5 @@ object GogoAnimeVC : ShowApi(
private fun getAndUnpack(string: String): String? = JsUnpacker(getPacked(string)).unpack()
private val qualityRegex = Regex("(\\d+)P")
}
}*/

0 comments on commit c10db51

Please sign in to comment.