kissmanga update (#140)
* updated to match internal source * updated version code * reverted extVersionSuffix * updated to latest LibVersion updated extVersion * fixed suffix since doesn't need to increment since lib did.
This commit is contained in:
parent
b3b22a9854
commit
9330c99347
|
@ -5,9 +5,9 @@ ext {
|
||||||
appName = 'Tachiyomi: Kissmanga'
|
appName = 'Tachiyomi: Kissmanga'
|
||||||
pkgNameSuffix = "en.kissmanga"
|
pkgNameSuffix = "en.kissmanga"
|
||||||
extClass = '.Kissmanga'
|
extClass = '.Kissmanga'
|
||||||
extVersionCode = 2
|
extVersionCode = 3
|
||||||
extVersionSuffix = 2
|
extVersionSuffix = 0
|
||||||
libVersion = '1.0'
|
libVersion = '1.2'
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
|
|
|
@ -44,7 +44,32 @@ class Kissmanga : ParsedHttpSource() {
|
||||||
val manga = SManga.create()
|
val manga = SManga.create()
|
||||||
element.select("td a:eq(0)").first().let {
|
element.select("td a:eq(0)").first().let {
|
||||||
manga.setUrlWithoutDomain(it.attr("href"))
|
manga.setUrlWithoutDomain(it.attr("href"))
|
||||||
manga.title = it.text()
|
val title = it.text()
|
||||||
|
//check if cloudfire email obfuscation is affecting title name
|
||||||
|
if (title.contains("[email protected]", true)) {
|
||||||
|
try {
|
||||||
|
var str: String = it.html()
|
||||||
|
//get the number
|
||||||
|
str = str.substringAfter("data-cfemail=\"")
|
||||||
|
str = str.substringBefore("\">[email")
|
||||||
|
val sb = StringBuilder()
|
||||||
|
//convert number to char
|
||||||
|
val r = Integer.valueOf(str.substring(0, 2), 16)!!
|
||||||
|
var i = 2
|
||||||
|
while (i < str.length) {
|
||||||
|
val c = (Integer.valueOf(str.substring(i, i + 2), 16) xor r).toChar()
|
||||||
|
sb.append(c)
|
||||||
|
i += 2
|
||||||
|
}
|
||||||
|
//replace the new word into the title
|
||||||
|
manga.title = title.replace("[email protected]", sb.toString(), true)
|
||||||
|
} catch (e: Exception) {
|
||||||
|
//on error just default to obfuscated title
|
||||||
|
manga.title = title
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
manga.title = title
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return manga
|
return manga
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue