From 249544d2b11a7ae231f509f807dee5b53244eb8e Mon Sep 17 00:00:00 2001 From: gedoor Date: Wed, 10 Jun 2020 21:10:31 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=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/service/help/ReadBook.kt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/io/legado/app/service/help/ReadBook.kt b/app/src/main/java/io/legado/app/service/help/ReadBook.kt index d008ad7e9..ef15098b0 100644 --- a/app/src/main/java/io/legado/app/service/help/ReadBook.kt +++ b/app/src/main/java/io/legado/app/service/help/ReadBook.kt @@ -40,7 +40,6 @@ object ReadBook { fun resetData(book: Book) { this.book = book - titleDate.postValue(book.name) durChapterIndex = book.durChapterIndex durPageIndex = book.durChapterPos isLocalBook = book.origin == BookType.local @@ -48,11 +47,11 @@ object ReadBook { prevTextChapter = null curTextChapter = null nextTextChapter = null + titleDate.postValue(book.name) upWebBook(book) } - fun upWebBook(book: Book?) { - book ?: return + fun upWebBook(book: Book) { webBook = if (book.origin == BookType.local) { null } else {