This commit is contained in:
kunfei
2022-10-20 20:26:53 +08:00
parent 0bd4f08ecc
commit 30adf4ea1d
@@ -120,8 +120,12 @@ data class SearchScope(private var scope: String) {
} }
if (list.isEmpty()) { if (list.isEmpty()) {
scope = "" scope = ""
stateLiveData.postValue(scope) appDb.bookSourceDao.allEnabled.let {
return appDb.bookSourceDao.allEnabled if (it.isNotEmpty()) {
stateLiveData.postValue(scope)
list.addAll(it)
}
}
} }
return list.sortedBy { it.customOrder } return list.sortedBy { it.customOrder }
} }