pull/32/head
kunfei 5 years ago
parent 030b450000
commit 277406e0e6
  1. 5
      app/src/main/java/io/legado/app/ui/main/bookshelf/BookshelfViewModel.kt

@ -31,10 +31,9 @@ class BookshelfViewModel(application: Application) : BaseViewModel(application)
fun upChapterList() { fun upChapterList() {
execute { execute {
App.db.bookDao().getRecentRead().map { book -> App.db.bookDao().getRecentRead().forEach { book ->
if (book.origin != BookType.local) { if (book.origin != BookType.local) {
val bookSource = App.db.bookSourceDao().getBookSource(book.origin) App.db.bookSourceDao().getBookSource(book.origin)?.let { bookSource ->
bookSource?.let {
synchronized(this) { synchronized(this) {
updateList.add(book.bookUrl) updateList.add(book.bookUrl)
postEvent(Bus.UP_BOOK, book.bookUrl) postEvent(Bus.UP_BOOK, book.bookUrl)

Loading…
Cancel
Save