diff --git a/app/src/main/java/io/legado/app/utils/HtmlFormatter.kt b/app/src/main/java/io/legado/app/utils/HtmlFormatter.kt index e91ca426655b..7bf485c025f0 100644 --- a/app/src/main/java/io/legado/app/utils/HtmlFormatter.kt +++ b/app/src/main/java/io/legado/app/utils/HtmlFormatter.kt @@ -17,7 +17,7 @@ object HtmlFormatter { private val notImgHtmlRegex = "])[^<>]*>".toRegex() private val otherHtmlRegex = "])[^<>]*>".toRegex() private val formatImagePattern = Pattern.compile( - "]* src *= *\"([^\"{>]*\\{(?:[^{}]|\\{[^}>]+\\})+\\})\"[^>]*>|]* data-[^=>]*= *\"([^\">]*)\"[^>]*>|]* src *= *\"([^\">]*)\"[^>]*>", + "]*\\ssrc\\s*=\\s*\"([^\"{>]*\\{(?:[^{}]|\\{[^}>]+\\})+\\})\"[^>]*>|]*\\sdata-[^=>]*=\\s*\"([^\">]*)\"[^>]*>|]*\\ssrc\\s*=\\s*\"([^\">]*)\"[^>]*>", Pattern.CASE_INSENSITIVE )