mirror of
https://github.com/kodjodevf/mangayomi-extensions.git
synced 2026-02-14 10:51:17 +00:00
anime(animekai): pagination fix
This commit is contained in:
@@ -6,7 +6,7 @@ const mangayomiSources = [{
|
|||||||
"iconUrl": "https://www.google.com/s2/favicons?sz=256&domain=https://animekai.to/",
|
"iconUrl": "https://www.google.com/s2/favicons?sz=256&domain=https://animekai.to/",
|
||||||
"typeSource": "single",
|
"typeSource": "single",
|
||||||
"itemType": 1,
|
"itemType": 1,
|
||||||
"version": "0.0.2",
|
"version": "0.0.3",
|
||||||
"pkgPath": "anime/src/en/animekai.js"
|
"pkgPath": "anime/src/en/animekai.js"
|
||||||
}];
|
}];
|
||||||
|
|
||||||
@@ -68,13 +68,11 @@ class DefaultExtension extends MProvider {
|
|||||||
slug += `&page=${page}`;
|
slug += `&page=${page}`;
|
||||||
|
|
||||||
var list = []
|
var list = []
|
||||||
var hasNextPage = false
|
|
||||||
|
|
||||||
var body = await this.getPage(slug);
|
var body = await this.getPage(slug);
|
||||||
|
|
||||||
var paginations = body.select(".pagination > li")
|
var paginations = body.select(".pagination > li")
|
||||||
|
var hasNextPage = paginations.length > 0 ? !paginations[paginations.length - 1].className.includes("active") : false
|
||||||
var hasNextPage = !paginations[paginations.length - 1].className.includes("active")
|
|
||||||
|
|
||||||
var titlePref = this.getPreference("animekai_title_lang")
|
var titlePref = this.getPreference("animekai_title_lang")
|
||||||
var animes = body.selectFirst(".aitem-wrapper").select(".aitem")
|
var animes = body.selectFirst(".aitem-wrapper").select(".aitem")
|
||||||
@@ -106,7 +104,6 @@ class DefaultExtension extends MProvider {
|
|||||||
state.forEach(item => {
|
state.forEach(item => {
|
||||||
if (item.state) {
|
if (item.state) {
|
||||||
rd.push(item.value)
|
rd.push(item.value)
|
||||||
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
return rd
|
return rd
|
||||||
|
|||||||
Reference in New Issue
Block a user