From 683fc3bef8dc043666b87377adc6ef12ee748788 Mon Sep 17 00:00:00 2001 From: gedoor Date: Sun, 26 Sep 2021 13:41:39 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/help/http/BackstageWebView.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/src/main/java/io/legado/app/help/http/BackstageWebView.kt b/app/src/main/java/io/legado/app/help/http/BackstageWebView.kt index 8cfff3e6c..bfcb5dae7 100644 --- a/app/src/main/java/io/legado/app/help/http/BackstageWebView.kt +++ b/app/src/main/java/io/legado/app/help/http/BackstageWebView.kt @@ -145,11 +145,13 @@ class BackstageWebView( callback?.onError(e) } mHandler.removeCallbacks(this) + destroy() return@evaluateJavascript } if (retry > 30) { callback?.onError(NoStackTraceException("js执行超时")) mHandler.removeCallbacks(this) + destroy() return@evaluateJavascript } retry++ @@ -170,6 +172,7 @@ class BackstageWebView( } catch (e: Exception) { callback?.onError(e) } + destroy() } } }