mirror of
https://github.com/kodjodevf/mangayomi-extensions.git
synced 2026-02-15 11:21:11 +00:00
Refactor
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import 'dart:convert';
|
||||
import 'package:bridge_lib/bridge_lib.dart';
|
||||
|
||||
searchManga(MangaModel manga) async {
|
||||
searchManga(MManga manga) async {
|
||||
final url = "${manga.baseUrl}/search?query=${manga.query}";
|
||||
final data = {"url": url, "sourceId": manga.sourceId};
|
||||
final res = await MBridge.http('GET', json.encode(data));
|
||||
@@ -35,7 +35,7 @@ searchManga(MangaModel manga) async {
|
||||
return manga;
|
||||
}
|
||||
|
||||
getPopularManga(MangaModel manga) async {
|
||||
getPopularManga(MManga manga) async {
|
||||
final url = "${manga.baseUrl}/filterList?page=${manga.page}&sortBy=views&asc=false";
|
||||
final data = {"url": url, "sourceId": manga.sourceId};
|
||||
final res = await MBridge.http('GET', json.encode(data));
|
||||
@@ -57,7 +57,7 @@ getPopularManga(MangaModel manga) async {
|
||||
return manga;
|
||||
}
|
||||
|
||||
getMangaDetail(MangaModel manga) async {
|
||||
getMangaDetail(MManga manga) async {
|
||||
final statusList = [
|
||||
{
|
||||
"complete": 1,
|
||||
@@ -99,7 +99,7 @@ getMangaDetail(MangaModel manga) async {
|
||||
return manga;
|
||||
}
|
||||
|
||||
getLatestUpdatesManga(MangaModel manga) async {
|
||||
getLatestUpdatesManga(MManga manga) async {
|
||||
final url = "${manga.baseUrl}/latest-release?page=${manga.page}";
|
||||
final data = {"url": url, "sourceId": manga.sourceId};
|
||||
final res = await MBridge.http('GET', json.encode(data));
|
||||
@@ -121,7 +121,7 @@ getLatestUpdatesManga(MangaModel manga) async {
|
||||
return manga;
|
||||
}
|
||||
|
||||
getChapterUrl(MangaModel manga) async {
|
||||
getChapterPages(MManga manga) async {
|
||||
final datas = {"url": manga.link, "sourceId": manga.sourceId};
|
||||
final res = await MBridge.http('GET', json.encode(datas));
|
||||
if (res.isEmpty) {
|
||||
@@ -1,7 +1,7 @@
|
||||
import '../../../model/source.dart';
|
||||
import '../../../utils/utils.dart';
|
||||
|
||||
const mmrcmsVersion = "0.0.2";
|
||||
const mmrcmsVersion = "0.0.3";
|
||||
const mmrcmsSourceCodeUrl =
|
||||
"https://raw.githubusercontent.com/kodjodevf/mangayomi-extensions/main/manga/multisrc/mmrcms/mmrcms-v$mmrcmsVersion.dart";
|
||||
const defaultDateFormat = "d MMM. yyyy";
|
||||
|
||||
Reference in New Issue
Block a user