Cleanup library update a bit
This commit is contained in:
parent
a29ddaaf1c
commit
4e8142b5b8
@ -361,11 +361,11 @@ class LibraryUpdateService(
|
|||||||
withIOContext {
|
withIOContext {
|
||||||
mangaToUpdate.groupBy { it.source }
|
mangaToUpdate.groupBy { it.source }
|
||||||
.filterNot { it.key in LIBRARY_UPDATE_EXCLUDED_SOURCES }
|
.filterNot { it.key in LIBRARY_UPDATE_EXCLUDED_SOURCES }
|
||||||
.values.map { mangaInSource ->
|
.values
|
||||||
|
.map { mangaInSource ->
|
||||||
async {
|
async {
|
||||||
semaphore.withPermit {
|
semaphore.withPermit {
|
||||||
mangaInSource
|
mangaInSource.forEach { manga ->
|
||||||
.onEach { manga ->
|
|
||||||
if (updateJob?.isActive != true) {
|
if (updateJob?.isActive != true) {
|
||||||
return@async
|
return@async
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user