This commit is contained in:
tom5079
2020-09-07 10:00:10 +09:00
parent 6f6956ce27
commit f408a91176
6 changed files with 11 additions and 10 deletions

View File

@@ -328,9 +328,11 @@ class DownloadService : Service() {
}
}
reader.requestBuilders.filterIndexed { index, _ -> progress[galleryID]?.get(index)?.isInfinite() != true }.forEachIndexed { index, it ->
val request = it.tag(Tag(galleryID, index, startId)).build()
client.newCall(request).enqueue(callback)
reader.requestBuilders.forEachIndexed { index, it ->
if (progress[galleryID]?.get(index)?.isInfinite() != true) {
val request = it.tag(Tag(galleryID, index, startId)).build()
client.newCall(request).enqueue(callback)
}
}
queued.forEach { download(it) }