From bd09590d36fed68e4307c49c2948547ec4af2b12 Mon Sep 17 00:00:00 2001 From: kunfei Date: Fri, 6 Sep 2019 11:45:48 +0800 Subject: [PATCH] up --- .../legado/app/model/webbook/SourceDebug.kt | 20 +++++++++---------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/app/src/main/java/io/legado/app/model/webbook/SourceDebug.kt b/app/src/main/java/io/legado/app/model/webbook/SourceDebug.kt index cd599f54b..97008b566 100644 --- a/app/src/main/java/io/legado/app/model/webbook/SourceDebug.kt +++ b/app/src/main/java/io/legado/app/model/webbook/SourceDebug.kt @@ -60,17 +60,15 @@ class SourceDebug(private val webBook: WebBook, callback: Callback) { fun startDebug(key: String) { cancelDebug() startTime = System.currentTimeMillis() - with(webBook) { - if (key.isAbsUrl()) { - val book = Book() - book.origin = sourceUrl - book.bookUrl = key - printLog(sourceUrl, 1, "开始访问$key") - infoDebug(book) - } else { - printLog(sourceUrl, 1, "开始搜索关键字$key") - searchDebug(key) - } + if (key.isAbsUrl()) { + val book = Book() + book.origin = webBook.sourceUrl + book.bookUrl = key + printLog(webBook.sourceUrl, 1, "开始访问$key") + infoDebug(book) + } else { + printLog(webBook.sourceUrl, 1, "开始搜索关键字$key") + searchDebug(key) } }