fix isDownloading logic

Signed-off-by: alperozturk <alper_ozturk@proton.me>
This commit is contained in:
alperozturk 2024-12-12 13:39:26 +01:00 committed by Alper Öztürk
parent d4d7f60f2c
commit 805858aa78

View file

@ -47,11 +47,10 @@ class FileDownloadHelper {
return false
}
return if (file.isFolder) {
SyncWorker.isDownloading(file.decryptedRemotePath)
} else {
FileDownloadWorker.isDownloading(user.accountName, file.fileId)
}
return FileDownloadWorker.isDownloading(
user.accountName,
file.fileId
) || SyncWorker.isDownloading(file.decryptedRemotePath)
}
fun cancelPendingOrCurrentDownloads(user: User?, files: List<OCFile>?) {