diff --git a/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt b/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt index 81364c11e..258e8b52d 100644 --- a/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt +++ b/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt @@ -135,9 +135,8 @@ class BookSourceActivity : VMBaseActivity(R.layout.activity } bookSourceLiveDate?.observe(this, Observer { search_view.queryHint = getString(R.string.search_book_source_num, it.size) - val diffResult = DiffUtil.calculateDiff( - DiffCallBack(adapter.getItems(), it) - ) + val diffResult = DiffUtil + .calculateDiff(DiffCallBack(adapter.getItems(), it)) adapter.setItemsNoNotify(it) diffResult.dispatchUpdatesTo(adapter) }) diff --git a/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt b/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt index 09eb27e39..0a2c2f0bd 100644 --- a/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt +++ b/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt @@ -91,9 +91,8 @@ class RssSourceActivity : VMBaseActivity(R.layout.activity_r sourceLiveData?.removeObservers(this) sourceLiveData = App.db.rssSourceDao().liveAll() sourceLiveData?.observe(this, Observer { - val diffResult = DiffUtil.calculateDiff( - DiffCallBack(adapter.getItems(), it) - ) + val diffResult = DiffUtil + .calculateDiff(DiffCallBack(adapter.getItems(), it)) adapter.setItemsNoNotify(it) diffResult.dispatchUpdatesTo(adapter) })