Update HtmlFormatter.kt

优化
pull/1123/head
bushixuanqi 3 years ago committed by GitHub
parent a5319a8a20
commit 7f7e472bf8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      app/src/main/java/io/legado/app/utils/HtmlFormatter.kt

@ -59,16 +59,16 @@ object HtmlFormatter {
do{
val url = matcher.group(1)!!
val pos = url.indexOf(',')
val urlBefore = url.substringBefore(',')
sb.append(keepImgHtml.substring(appendPos, matcher.start()).replace("\n","\n  ")) //非图片部分换行缩减
sb.append(
"<img src=\"${
NetworkUtils.getAbsoluteURL(
redirectUrl,
url.substring(0, pos)
urlBefore
)
},${
url.substring(pos)
}${
url.substring(urlBefore.length)
}\">"
)
appendPos = matcher.end()

Loading…
Cancel
Save