diff --git a/app/src/main/assets/updateLog.md b/app/src/main/assets/updateLog.md index 8155ed74e..54d4d2906 100644 --- a/app/src/main/assets/updateLog.md +++ b/app/src/main/assets/updateLog.md @@ -5,6 +5,7 @@ **2020/05/02** * 修复不停换源的bug +* 修复本地书籍自动换源 **2020/05/01** * 尝试修复朗读时可能错位的bug diff --git a/app/src/main/java/io/legado/app/ui/book/read/ReadBookViewModel.kt b/app/src/main/java/io/legado/app/ui/book/read/ReadBookViewModel.kt index d73ffd07a..a4755213d 100644 --- a/app/src/main/java/io/legado/app/ui/book/read/ReadBookViewModel.kt +++ b/app/src/main/java/io/legado/app/ui/book/read/ReadBookViewModel.kt @@ -41,7 +41,7 @@ class ReadBookViewModel(application: Application) : BaseViewModel(application) { private fun initBook(book: Book) { if (ReadBook.book?.bookUrl != book.bookUrl) { ReadBook.resetData(book) - if (ReadBook.webBook == null) { + if (!book.isLocalBook() && ReadBook.webBook == null) { autoChangeSource(book.name, book.author) return } @@ -66,7 +66,7 @@ class ReadBookViewModel(application: Application) : BaseViewModel(application) { isInitFinish = true ReadBook.titleDate.postValue(book.name) ReadBook.upWebBook(book) - if (ReadBook.webBook == null) { + if (!book.isLocalBook() && ReadBook.webBook == null) { autoChangeSource(book.name, book.author) return }