diff --git a/app/src/main/java/io/legado/app/ui/readbook/ReadBookViewModel.kt b/app/src/main/java/io/legado/app/ui/readbook/ReadBookViewModel.kt index f48537b9e..96a5711e0 100644 --- a/app/src/main/java/io/legado/app/ui/readbook/ReadBookViewModel.kt +++ b/app/src/main/java/io/legado/app/ui/readbook/ReadBookViewModel.kt @@ -209,6 +209,7 @@ class ReadBookViewModel(application: Application) : BaseViewModel(application) { bookData.value?.let { App.db.bookDao().delete(it.bookUrl) } + App.db.bookDao().insert(book) bookData.postValue(book) bookSource = App.db.bookSourceDao().getBookSource(book.origin) if (book.tocUrl.isEmpty()) {