mirror of
https://github.com/nextcloud/android.git
synced 2024-11-26 15:15:51 +03:00
Fix cancel and isDownloading
Signed-off-by: alperozturk <alper_ozturk@proton.me>
This commit is contained in:
parent
3b2824e80e
commit
2a0b754449
1 changed files with 5 additions and 4 deletions
|
@ -60,10 +60,11 @@ class FileDownloadHelper {
|
|||
return false
|
||||
}
|
||||
|
||||
return FileDownloadWorker.isDownloading(user.accountName, file.fileId) ||
|
||||
FileDownloadWorker.isDownloading(user.accountName, file.parentId) ||
|
||||
backgroundJobManager.isStartFileDownloadJobScheduled(user, file.fileId) ||
|
||||
backgroundJobManager.isStartFileDownloadJobScheduled(user, file.parentId)
|
||||
return if (file.isFolder) {
|
||||
backgroundJobManager.isStartFileDownloadJobScheduled(user, file.fileId)
|
||||
} else {
|
||||
FileDownloadWorker.isDownloading(user.accountName, file.fileId)
|
||||
}
|
||||
}
|
||||
|
||||
fun cancelPendingOrCurrentDownloads(user: User?, files: List<OCFile>?) {
|
||||
|
|
Loading…
Reference in a new issue