mirror of
https://github.com/null2264/yokai.git
synced 2025-06-21 10:44:42 +00:00
refactor(source/local): Convert to list after .map()
This commit is contained in:
parent
b8a2a4de47
commit
128e14882d
1 changed files with 2 additions and 2 deletions
|
@ -197,7 +197,7 @@ class LocalSource(private val context: Context) : CatalogueSource, UnmeteredSour
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
val mangas = mangaDirs.toList().map { mangaDir ->
|
val mangas = mangaDirs.map { mangaDir ->
|
||||||
async {
|
async {
|
||||||
SManga.create().apply {
|
SManga.create().apply {
|
||||||
title = mangaDir.name.orEmpty()
|
title = mangaDir.name.orEmpty()
|
||||||
|
@ -210,7 +210,7 @@ class LocalSource(private val context: Context) : CatalogueSource, UnmeteredSour
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}.awaitAll()
|
}.toList().awaitAll()
|
||||||
|
|
||||||
MangasPage(mangas, false)
|
MangasPage(mangas, false)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue