1
0
Fork 0

For #355 - Fixes coroutine scope

master
Jeff Boek 2019-02-11 15:39:40 -08:00
parent b9171cd99a
commit 29227e6f90
1 changed files with 2 additions and 2 deletions

View File

@ -30,7 +30,7 @@ class HistoryFragment : Fragment(), CoroutineScope {
lateinit var job: Job
override val coroutineContext: CoroutineContext
get() = Dispatchers.Main + job
get() = Dispatchers.Default + job
override fun onCreateView(
inflater: LayoutInflater,
@ -76,7 +76,7 @@ class HistoryFragment : Fragment(), CoroutineScope {
val eventEmitter = ActionBusFactory.get(this)
launch {
launch(Dispatchers.IO) {
val items = requireComponents.core.historyStorage.getVisited().map { HistoryItem(it) }
launch(Dispatchers.Main) {