pull/414/head
gedoor 4 years ago
parent c9a7d03c49
commit cb4cb26f58
  1. 6
      app/src/main/java/io/legado/app/model/analyzeRule/AnalyzeUrl.kt

@ -105,13 +105,11 @@ class AnalyzeUrl(
when { when {
ruleStr.startsWith("<js>") -> { ruleStr.startsWith("<js>") -> {
ruleStr = ruleStr.substring(4, ruleStr.lastIndexOf("<")) ruleStr = ruleStr.substring(4, ruleStr.lastIndexOf("<"))
ruleUrl = ruleUrl = evalJS(ruleStr, ruleUrl) as String
evalJS(ruleStr, ruleUrl) as String
} }
ruleStr.startsWith("@js", true) -> { ruleStr.startsWith("@js", true) -> {
ruleStr = ruleStr.substring(4) ruleStr = ruleStr.substring(4)
ruleUrl = ruleUrl = evalJS(ruleStr, ruleUrl) as String
evalJS(ruleStr, ruleUrl) as String
} }
else -> ruleUrl = ruleStr.replace("@result", ruleUrl) else -> ruleUrl = ruleStr.replace("@result", ruleUrl)
} }

Loading…
Cancel
Save