pull/1759/head
kunfei 3 years ago
parent 3a2ed37f1f
commit 18914f94a7
  1. 13
      app/src/main/java/io/legado/app/ui/book/read/ReadBookViewModel.kt

@ -211,13 +211,12 @@ class ReadBookViewModel(application: Application) : BaseViewModel(application) {
ReadBook.resetData(book)
ReadBook.upMsg(null)
ReadBook.loadContent(resetPageOffset = true)
}.timeout(60000)
.onError {
context.toastOnUi("换源失败\n${it.localizedMessage}")
ReadBook.upMsg(null)
}.onFinally {
postEvent(EventBus.SOURCE_CHANGED, book.bookUrl)
}
}.onError {
context.toastOnUi("换源失败\n${it.localizedMessage}")
ReadBook.upMsg(null)
}.onFinally {
postEvent(EventBus.SOURCE_CHANGED, book.bookUrl)
}
}
/**

Loading…
Cancel
Save