Added download database recovery

This commit is contained in:
tom5079
2022-01-31 11:04:52 +09:00
parent fc8355467b
commit 13f8d7b747
12 changed files with 117 additions and 40 deletions

View File

@@ -329,9 +329,8 @@ class DownloadService : Service() {
}
if (isCompleted(galleryID)) {
if (DownloadManager.getInstance(this@DownloadService)
.getDownloadFolder(galleryID) != null )
Cache.getInstance(this@DownloadService, galleryID).moveToDownload()
DownloadManager.getInstance(this@DownloadService).addDownloadFolder(galleryID)
Cache.getInstance(this@DownloadService, galleryID).moveToDownload()
notificationManager.cancel(galleryID)
startId?.let { stopSelf(it) }