mirror of
https://github.com/kodjodevf/mangayomi-extensions.git
synced 2026-02-14 02:41:39 +00:00
Refactor & fix videos extractor
This commit is contained in:
@@ -197,7 +197,6 @@ class ZoroTheme extends MProvider {
|
||||
.body;
|
||||
String epUrl = substringBefore(substringAfter(resE, "\"link\":\""), "\"");
|
||||
List<MVideo> a = [];
|
||||
|
||||
if (hosterSelection.contains(name) && typeSelection.contains(subDub)) {
|
||||
if (name.contains("Vidstreaming")) {
|
||||
a = await rapidCloudExtractor(epUrl, "Vidstreaming - $subDub");
|
||||
@@ -213,6 +212,141 @@ class ZoroTheme extends MProvider {
|
||||
return sortVideos(videos, source.id);
|
||||
}
|
||||
|
||||
Future<List<MVideo>> rapidCloudExtractor(String url, String name) async {
|
||||
final serverUrl = ['https://megacloud.tv', 'https://rapid-cloud.co'];
|
||||
|
||||
final serverType = url.startsWith('https://megacloud.tv') ? 0 : 1;
|
||||
final sourceUrl = [
|
||||
'/embed-2/ajax/e-1/getSources?id=',
|
||||
'/ajax/embed-6-v2/getSources?id='
|
||||
];
|
||||
final sourceSpliter = ['/e-1/', '/embed-6-v2/'];
|
||||
final id = url.split(sourceSpliter[serverType]).last.split('?').first;
|
||||
final resServer = (await client.get(
|
||||
Uri.parse('${serverUrl[serverType]}${sourceUrl[serverType]}$id'),
|
||||
headers: {"X-Requested-With": "XMLHttpRequest"}))
|
||||
.body;
|
||||
final encrypted = getMapValue(resServer, "encrypted");
|
||||
String videoResJson = "";
|
||||
List<MVideo> videos = [];
|
||||
if (encrypted == "true") {
|
||||
final ciphered = getMapValue(resServer, "sources");
|
||||
List<List<int>> indexPairs = await generateIndexPairs(serverType);
|
||||
var password = '';
|
||||
String ciphertext = ciphered;
|
||||
int index = 0;
|
||||
for (List<int> item in json.decode(json.encode(indexPairs))) {
|
||||
int start = item.first + index;
|
||||
int end = start + item.last;
|
||||
String passSubstr = ciphered.substring(start, end);
|
||||
password += passSubstr;
|
||||
ciphertext = ciphertext.replaceFirst(passSubstr, "");
|
||||
index += item.last;
|
||||
}
|
||||
videoResJson = decryptAESCryptoJS(ciphertext, password);
|
||||
} else {
|
||||
videoResJson = resServer;
|
||||
}
|
||||
|
||||
String masterUrl =
|
||||
((json.decode(videoResJson) as List<Map<String, dynamic>>)
|
||||
.first)['file'];
|
||||
String type = ((json.decode(videoResJson) as List<Map<String, dynamic>>)
|
||||
.first)['type'];
|
||||
|
||||
final tracks = (json.decode(resServer)['tracks'] as List)
|
||||
.where((e) => e['kind'] == 'captions' ? true : false)
|
||||
.toList();
|
||||
List<MTrack> subtitles = [];
|
||||
|
||||
for (var sub in tracks) {
|
||||
try {
|
||||
MTrack subtitle = MTrack();
|
||||
subtitle
|
||||
..label = sub["label"]
|
||||
..file = sub["file"];
|
||||
subtitles.add(subtitle);
|
||||
} catch (_) {}
|
||||
}
|
||||
|
||||
if (type == "hls") {
|
||||
final masterPlaylistRes = (await client.get(Uri.parse(masterUrl))).body;
|
||||
|
||||
for (var it in substringAfter(masterPlaylistRes, "#EXT-X-STREAM-INF:")
|
||||
.split("#EXT-X-STREAM-INF:")) {
|
||||
final quality =
|
||||
"${substringBefore(substringBefore(substringAfter(substringAfter(it, "RESOLUTION="), "x"), ","), "\n")}p";
|
||||
|
||||
String videoUrl = substringBefore(substringAfter(it, "\n"), "\n");
|
||||
|
||||
if (!videoUrl.startsWith("http")) {
|
||||
videoUrl =
|
||||
"${masterUrl.split("/").sublist(0, masterUrl.split("/").length - 1).join("/")}/$videoUrl";
|
||||
}
|
||||
|
||||
MVideo video = MVideo();
|
||||
video
|
||||
..url = videoUrl
|
||||
..originalUrl = videoUrl
|
||||
..quality = "$name - $quality"
|
||||
..subtitles = subtitles;
|
||||
videos.add(video);
|
||||
}
|
||||
} else {
|
||||
MVideo video = MVideo();
|
||||
video
|
||||
..url = masterUrl
|
||||
..originalUrl = masterUrl
|
||||
..quality = "$name - Default"
|
||||
..subtitles = subtitles;
|
||||
videos.add(video);
|
||||
}
|
||||
return videos;
|
||||
}
|
||||
|
||||
Future<List<List<int>>> generateIndexPairs(int serverType) async {
|
||||
final jsPlayerUrl = [
|
||||
"https://megacloud.tv/js/player/a/prod/e1-player.min.js",
|
||||
"https://rapid-cloud.co/js/player/prod/e6-player-v2.min.js"
|
||||
];
|
||||
final scriptText =
|
||||
(await client.get(Uri.parse(jsPlayerUrl[serverType]))).body;
|
||||
|
||||
final switchCode = scriptText.substring(
|
||||
scriptText.lastIndexOf('switch'), scriptText.indexOf('=partKey'));
|
||||
|
||||
List<int> indexes = [];
|
||||
for (var variableMatch
|
||||
in RegExp(r'=(\w+)').allMatches(switchCode).toList()) {
|
||||
final regex = RegExp(
|
||||
',${(variableMatch as RegExpMatch).group(1)}=((?:0x)?([0-9a-fA-F]+))');
|
||||
Match? match = regex.firstMatch(scriptText);
|
||||
|
||||
if (match != null) {
|
||||
String value = match.group(1);
|
||||
if (value.contains("0x")) {
|
||||
indexes.add(int.parse(substringAfter(value, "0x"), radix: 16));
|
||||
} else {
|
||||
indexes.add(int.parse(value));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return chunked(indexes, 2);
|
||||
}
|
||||
|
||||
List<List<int>> chunked(List<int> list, int size) {
|
||||
List<List<int>> chunks = [];
|
||||
for (int i = 0; i < list.length; i += size) {
|
||||
int end = list.length;
|
||||
if (i + size < list.length) {
|
||||
end = i + size;
|
||||
}
|
||||
chunks.add(list.sublist(i, end));
|
||||
}
|
||||
return chunks;
|
||||
}
|
||||
|
||||
MPages animeElementM(String res) {
|
||||
List<MManga> animeList = [];
|
||||
|
||||
|
||||
@@ -121,7 +121,6 @@ class AniFlix extends MProvider {
|
||||
final res = (await client.get(Uri.parse("${source.baseUrl}$url"),
|
||||
headers: getHeader(source.baseUrl)))
|
||||
.body;
|
||||
print(res);
|
||||
final jsonRes = json.decode(res)["streams"];
|
||||
List<MVideo> videos = [];
|
||||
final hosterSelection = preferenceHosterSelection(source.id);
|
||||
@@ -181,7 +180,6 @@ class AniFlix extends MProvider {
|
||||
}
|
||||
|
||||
List<MVideo> sortVideos(List<MVideo> videos, int sourceId) {
|
||||
print(videos.length);
|
||||
String hoster = getPreferenceValue(sourceId, "preferred_hoster");
|
||||
String sub = getPreferenceValue(sourceId, "preferred_sub");
|
||||
videos.sort((MVideo a, MVideo b) {
|
||||
|
||||
@@ -311,58 +311,60 @@ class Aniwave extends MProvider {
|
||||
List<String> keys = json.decode((await client.get(Uri.parse(
|
||||
"https://raw.githubusercontent.com/Claudemirovsky/worstsource-keys/keys/keys.json")))
|
||||
.body);
|
||||
List<MVideo> videoList = [];
|
||||
final host = Uri.parse(url).host;
|
||||
final apiUrl = await getApiUrl(url, keys);
|
||||
|
||||
final res = await client.get(Uri.parse(apiUrl, headers: {
|
||||
final res = await client.get(Uri.parse(apiUrl), headers: {
|
||||
"Host": host,
|
||||
"Referer": Uri.decodeComponent(url),
|
||||
"X-Requested-With": "XMLHttpRequest"
|
||||
}));
|
||||
});
|
||||
final result = json.decode(res.body)['result'];
|
||||
|
||||
if (res.statusCode != 200) return [];
|
||||
if (result != 404) {
|
||||
String masterUrl =
|
||||
((result['sources'] as List<Map<String, dynamic>>).first)['file'];
|
||||
final tracks = (result['tracks'] as List)
|
||||
.where((e) => e['kind'] == 'captions' ? true : false)
|
||||
.toList();
|
||||
List<MTrack> subtitles = [];
|
||||
|
||||
String masterUrl = ((json.decode(res.body)['result']['sources']
|
||||
as List<Map<String, dynamic>>)
|
||||
.first)['file'];
|
||||
final tracks = (json.decode(res.body)['result']['tracks'] as List)
|
||||
.where((e) => e['kind'] == 'captions' ? true : false)
|
||||
.toList();
|
||||
List<MTrack> subtitles = [];
|
||||
|
||||
for (var sub in tracks) {
|
||||
try {
|
||||
MTrack subtitle = MTrack();
|
||||
subtitle
|
||||
..label = sub["label"]
|
||||
..file = sub["file"];
|
||||
subtitles.add(subtitle);
|
||||
} catch (_) {}
|
||||
}
|
||||
List<MVideo> videoList = [];
|
||||
final masterPlaylistRes = (await client.get(Uri.parse(masterUrl))).body;
|
||||
|
||||
for (var it in substringAfter(masterPlaylistRes, "#EXT-X-STREAM-INF:")
|
||||
.split("#EXT-X-STREAM-INF:")) {
|
||||
final quality =
|
||||
"${substringBefore(substringBefore(substringAfter(substringAfter(it, "RESOLUTION="), "x"), ","), "\n")}p";
|
||||
|
||||
String videoUrl = substringBefore(substringAfter(it, "\n"), "\n");
|
||||
|
||||
if (!videoUrl.startsWith("http")) {
|
||||
videoUrl =
|
||||
"${masterUrl.split("/").sublist(0, masterUrl.split("/").length - 1).join("/")}/$videoUrl";
|
||||
for (var sub in tracks) {
|
||||
try {
|
||||
MTrack subtitle = MTrack();
|
||||
subtitle
|
||||
..label = sub["label"]
|
||||
..file = sub["file"];
|
||||
subtitles.add(subtitle);
|
||||
} catch (_) {}
|
||||
}
|
||||
|
||||
MVideo video = MVideo();
|
||||
video
|
||||
..url = videoUrl
|
||||
..originalUrl = videoUrl
|
||||
..quality = "$name - $type - $quality"
|
||||
..headers = {"Referer": "https://$host/"}
|
||||
..subtitles = subtitles;
|
||||
videoList.add(video);
|
||||
final masterPlaylistRes = (await client.get(Uri.parse(masterUrl))).body;
|
||||
|
||||
for (var it in substringAfter(masterPlaylistRes, "#EXT-X-STREAM-INF:")
|
||||
.split("#EXT-X-STREAM-INF:")) {
|
||||
final quality =
|
||||
"${substringBefore(substringBefore(substringAfter(substringAfter(it, "RESOLUTION="), "x"), ","), "\n")}p";
|
||||
|
||||
String videoUrl = substringBefore(substringAfter(it, "\n"), "\n");
|
||||
|
||||
if (!videoUrl.startsWith("http")) {
|
||||
videoUrl =
|
||||
"${masterUrl.split("/").sublist(0, masterUrl.split("/").length - 1).join("/")}/$videoUrl";
|
||||
}
|
||||
|
||||
MVideo video = MVideo();
|
||||
video
|
||||
..url = videoUrl
|
||||
..originalUrl = videoUrl
|
||||
..quality = "$name - $type - $quality"
|
||||
..headers = {"Referer": "https://$host/"}
|
||||
..subtitles = subtitles;
|
||||
videoList.add(video);
|
||||
}
|
||||
}
|
||||
|
||||
return videoList;
|
||||
}
|
||||
|
||||
|
||||
@@ -210,6 +210,141 @@ class NineAnimeTv extends MProvider {
|
||||
return MPages(animeList, true);
|
||||
}
|
||||
|
||||
Future<List<MVideo>> rapidCloudExtractor(String url, String name) async {
|
||||
final serverUrl = ['https://megacloud.tv', 'https://rapid-cloud.co'];
|
||||
|
||||
final serverType = url.startsWith('https://megacloud.tv') ? 0 : 1;
|
||||
final sourceUrl = [
|
||||
'/embed-2/ajax/e-1/getSources?id=',
|
||||
'/ajax/embed-6-v2/getSources?id='
|
||||
];
|
||||
final sourceSpliter = ['/e-1/', '/embed-6-v2/'];
|
||||
final id = url.split(sourceSpliter[serverType]).last.split('?').first;
|
||||
final resServer = (await client.get(
|
||||
Uri.parse('${serverUrl[serverType]}${sourceUrl[serverType]}$id'),
|
||||
headers: {"X-Requested-With": "XMLHttpRequest"}))
|
||||
.body;
|
||||
final encrypted = getMapValue(resServer, "encrypted");
|
||||
String videoResJson = "";
|
||||
List<MVideo> videos = [];
|
||||
if (encrypted == "true") {
|
||||
final ciphered = getMapValue(resServer, "sources");
|
||||
List<List<int>> indexPairs = await generateIndexPairs(serverType);
|
||||
var password = '';
|
||||
String ciphertext = ciphered;
|
||||
int index = 0;
|
||||
for (List<int> item in json.decode(json.encode(indexPairs))) {
|
||||
int start = item.first + index;
|
||||
int end = start + item.last;
|
||||
String passSubstr = ciphered.substring(start, end);
|
||||
password += passSubstr;
|
||||
ciphertext = ciphertext.replaceFirst(passSubstr, "");
|
||||
index += item.last;
|
||||
}
|
||||
videoResJson = decryptAESCryptoJS(ciphertext, password);
|
||||
} else {
|
||||
videoResJson = resServer;
|
||||
}
|
||||
|
||||
String masterUrl =
|
||||
((json.decode(videoResJson) as List<Map<String, dynamic>>)
|
||||
.first)['file'];
|
||||
String type = ((json.decode(videoResJson) as List<Map<String, dynamic>>)
|
||||
.first)['type'];
|
||||
|
||||
final tracks = (json.decode(resServer)['tracks'] as List)
|
||||
.where((e) => e['kind'] == 'captions' ? true : false)
|
||||
.toList();
|
||||
List<MTrack> subtitles = [];
|
||||
|
||||
for (var sub in tracks) {
|
||||
try {
|
||||
MTrack subtitle = MTrack();
|
||||
subtitle
|
||||
..label = sub["label"]
|
||||
..file = sub["file"];
|
||||
subtitles.add(subtitle);
|
||||
} catch (_) {}
|
||||
}
|
||||
|
||||
if (type == "hls") {
|
||||
final masterPlaylistRes = (await client.get(Uri.parse(masterUrl))).body;
|
||||
|
||||
for (var it in substringAfter(masterPlaylistRes, "#EXT-X-STREAM-INF:")
|
||||
.split("#EXT-X-STREAM-INF:")) {
|
||||
final quality =
|
||||
"${substringBefore(substringBefore(substringAfter(substringAfter(it, "RESOLUTION="), "x"), ","), "\n")}p";
|
||||
|
||||
String videoUrl = substringBefore(substringAfter(it, "\n"), "\n");
|
||||
|
||||
if (!videoUrl.startsWith("http")) {
|
||||
videoUrl =
|
||||
"${masterUrl.split("/").sublist(0, masterUrl.split("/").length - 1).join("/")}/$videoUrl";
|
||||
}
|
||||
|
||||
MVideo video = MVideo();
|
||||
video
|
||||
..url = videoUrl
|
||||
..originalUrl = videoUrl
|
||||
..quality = "$name - $quality"
|
||||
..subtitles = subtitles;
|
||||
videos.add(video);
|
||||
}
|
||||
} else {
|
||||
MVideo video = MVideo();
|
||||
video
|
||||
..url = masterUrl
|
||||
..originalUrl = masterUrl
|
||||
..quality = "$name - Default"
|
||||
..subtitles = subtitles;
|
||||
videos.add(video);
|
||||
}
|
||||
return videos;
|
||||
}
|
||||
|
||||
Future<List<List<int>>> generateIndexPairs(int serverType) async {
|
||||
final jsPlayerUrl = [
|
||||
"https://megacloud.tv/js/player/a/prod/e1-player.min.js",
|
||||
"https://rapid-cloud.co/js/player/prod/e6-player-v2.min.js"
|
||||
];
|
||||
final scriptText =
|
||||
(await client.get(Uri.parse(jsPlayerUrl[serverType]))).body;
|
||||
|
||||
final switchCode = scriptText.substring(
|
||||
scriptText.lastIndexOf('switch'), scriptText.indexOf('=partKey'));
|
||||
|
||||
List<int> indexes = [];
|
||||
for (var variableMatch
|
||||
in RegExp(r'=(\w+)').allMatches(switchCode).toList()) {
|
||||
final regex = RegExp(
|
||||
',${(variableMatch as RegExpMatch).group(1)}=((?:0x)?([0-9a-fA-F]+))');
|
||||
Match? match = regex.firstMatch(scriptText);
|
||||
|
||||
if (match != null) {
|
||||
String value = match.group(1);
|
||||
if (value.contains("0x")) {
|
||||
indexes.add(int.parse(substringAfter(value, "0x"), radix: 16));
|
||||
} else {
|
||||
indexes.add(int.parse(value));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return chunked(indexes, 2);
|
||||
}
|
||||
|
||||
List<List<int>> chunked(List<int> list, int size) {
|
||||
List<List<int>> chunks = [];
|
||||
for (int i = 0; i < list.length; i += size) {
|
||||
int end = list.length;
|
||||
if (i + size < list.length) {
|
||||
end = i + size;
|
||||
}
|
||||
chunks.add(list.sublist(i, end));
|
||||
}
|
||||
return chunks;
|
||||
}
|
||||
|
||||
@override
|
||||
List<dynamic> getFilterList(MSource source) {
|
||||
return [
|
||||
|
||||
@@ -104,7 +104,6 @@ class FrAnime extends MProvider {
|
||||
if (url.contains("s=")) {
|
||||
int seasonNumber =
|
||||
int.parse(substringBefore(substringAfter(url, "s="), "&"));
|
||||
print(seasonNumber);
|
||||
videoBaseUrl += "${seasonNumber - 1}/";
|
||||
seasonsJson = seasons[seasonNumber - 1];
|
||||
} else {
|
||||
@@ -114,7 +113,6 @@ class FrAnime extends MProvider {
|
||||
var episode = episodesJson.first;
|
||||
if (url.contains("ep=")) {
|
||||
int episodeNumber = int.parse(substringAfter(url, "ep="));
|
||||
print(episodeNumber);
|
||||
episode = episodesJson[episodeNumber - 1];
|
||||
videoBaseUrl += "${episodeNumber - 1}";
|
||||
} else {
|
||||
|
||||
@@ -40,7 +40,6 @@ class OploVerz extends MProvider {
|
||||
final res = (await client.get(Uri.parse(url))).body;
|
||||
MManga anime = MManga();
|
||||
final status = xpath(res, '//*[@class="alternati"]/span[2]/text()');
|
||||
print(status);
|
||||
if (status.isNotEmpty) {
|
||||
anime.status = parseStatus(status.first, statusList);
|
||||
}
|
||||
|
||||
@@ -201,6 +201,7 @@ class Filma24 extends MProvider {
|
||||
final playlistUrl =
|
||||
RegExp(r'file:"(\S+?)"').firstMatch(playListUrlResponse)?.group(1) ??
|
||||
"";
|
||||
if (playlistUrl.isEmpty) return [];
|
||||
final masterPlaylistRes =
|
||||
await client.get(Uri.parse(playlistUrl), headers: headers);
|
||||
|
||||
@@ -232,6 +233,7 @@ class Filma24 extends MProvider {
|
||||
final playlistUrl =
|
||||
RegExp(r'file:"(\S+?)"').firstMatch(playListUrlResponse)?.group(1) ??
|
||||
"";
|
||||
if (playlistUrl.isEmpty) return [];
|
||||
final masterPlaylistRes = (await client.get(Uri.parse(playlistUrl))).body;
|
||||
for (var it in substringAfter(masterPlaylistRes, "#EXT-X-STREAM-INF:")
|
||||
.split("#EXT-X-STREAM-INF:")) {
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -8,7 +8,6 @@ import 'multisrc/mangabox/sources.dart';
|
||||
import 'multisrc/mangareader/sources.dart';
|
||||
import 'multisrc/mmrcms/sources.dart';
|
||||
import 'multisrc/nepnep/sources.dart';
|
||||
import 'src/all/batoto/sources.dart';
|
||||
import 'src/all/comick/sources.dart';
|
||||
import 'src/all/mangadex/sources.dart';
|
||||
import 'src/en/mangahere/source.dart';
|
||||
@@ -22,7 +21,6 @@ void main() {
|
||||
...mmrcmsSourcesList,
|
||||
...heancmsSourcesList,
|
||||
mangahereSource,
|
||||
...batotoSourcesList,
|
||||
...nepnepSourcesList,
|
||||
...mangaboxSourcesList
|
||||
];
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
Before Width: | Height: | Size: 3.6 KiB |
@@ -1,132 +0,0 @@
|
||||
import '../../../../model/source.dart';
|
||||
|
||||
const _batotoVersion = "0.0.6";
|
||||
const _batotoSourceCodeUrl =
|
||||
"https://raw.githubusercontent.com/kodjodevf/mangayomi-extensions/$branchName/manga/src/all/batoto/batoto.dart";
|
||||
|
||||
String _iconUrl =
|
||||
"https://raw.githubusercontent.com/kodjodevf/mangayomi-extensions/$branchName/manga/src/all/batoto/icon.png";
|
||||
const _baseUrl = 'https://bato.to';
|
||||
const _isNsfw = true;
|
||||
|
||||
List<String> _languages = [
|
||||
"all",
|
||||
"en",
|
||||
"ar",
|
||||
"bg",
|
||||
"zh",
|
||||
"cs",
|
||||
"da",
|
||||
"nl",
|
||||
"fil",
|
||||
"fi",
|
||||
"fr",
|
||||
"de",
|
||||
"el",
|
||||
"he",
|
||||
"hi",
|
||||
"hu",
|
||||
"id",
|
||||
"it",
|
||||
"ja",
|
||||
"ko",
|
||||
"ms",
|
||||
"pl",
|
||||
"pt",
|
||||
"pt-br",
|
||||
"ro",
|
||||
"ru",
|
||||
"es",
|
||||
"es-419",
|
||||
"sv",
|
||||
"th",
|
||||
"tr",
|
||||
"uk",
|
||||
"vi",
|
||||
"af",
|
||||
"sq",
|
||||
"am",
|
||||
"hy",
|
||||
"az",
|
||||
"be",
|
||||
"bn",
|
||||
"bs",
|
||||
"my",
|
||||
"km",
|
||||
"ca",
|
||||
"ceb",
|
||||
"zh-hk",
|
||||
"zh-tw",
|
||||
"hr",
|
||||
"en-us",
|
||||
"eo",
|
||||
"et",
|
||||
"fo",
|
||||
"ka",
|
||||
"gn",
|
||||
"gu",
|
||||
"ht",
|
||||
"ha",
|
||||
"is",
|
||||
"ig",
|
||||
"ga",
|
||||
"jv",
|
||||
"kn",
|
||||
"kk",
|
||||
"ku",
|
||||
"ky",
|
||||
"lo",
|
||||
"lv",
|
||||
"lt",
|
||||
"lb",
|
||||
"mk",
|
||||
"mg",
|
||||
"ml",
|
||||
"mt",
|
||||
"mi",
|
||||
"mr",
|
||||
"mn",
|
||||
"ne",
|
||||
"no",
|
||||
"ny",
|
||||
"ps",
|
||||
"fa",
|
||||
"rm",
|
||||
"sm",
|
||||
"sr",
|
||||
"sh",
|
||||
"st",
|
||||
"sn",
|
||||
"sd",
|
||||
"si",
|
||||
"sk",
|
||||
"sl",
|
||||
"so",
|
||||
"sw",
|
||||
"tg",
|
||||
"ta",
|
||||
"ti",
|
||||
"to",
|
||||
"tk",
|
||||
"ur",
|
||||
"uz",
|
||||
"yo",
|
||||
"zu",
|
||||
"eu",
|
||||
"pt-PT",
|
||||
];
|
||||
|
||||
List<Source> get batotoSourcesList => _batotoSourcesList;
|
||||
List<Source> _batotoSourcesList = _languages
|
||||
.map((e) => Source(
|
||||
name: 'Bato.to',
|
||||
baseUrl: _baseUrl,
|
||||
lang: e,
|
||||
typeSource: "bato.to",
|
||||
iconUrl: _iconUrl,
|
||||
dateFormat: "MMM dd,yyyy",
|
||||
isNsfw: _isNsfw,
|
||||
dateFormatLocale: "en",
|
||||
version: _batotoVersion,
|
||||
sourceCodeUrl: _batotoSourceCodeUrl))
|
||||
.toList();
|
||||
@@ -33,7 +33,6 @@ final _languages = [
|
||||
"it",
|
||||
"ja",
|
||||
"kk",
|
||||
"ko",
|
||||
"la",
|
||||
"lt",
|
||||
"ms",
|
||||
|
||||
@@ -135,7 +135,7 @@ class MangaHere extends MProvider {
|
||||
{"Ongoing": 0, "Completed": 1}
|
||||
];
|
||||
final res = (await client.get(Uri.parse("${source.baseUrl}/$url"),
|
||||
headers: headers))
|
||||
headers: getHeader(source.baseUrl)))
|
||||
.body;
|
||||
MManga manga = MManga();
|
||||
manga.author =
|
||||
|
||||
Reference in New Issue
Block a user