Skip to content

Commit

Permalink
Merge 'hotfix/download_malfunction'
Browse files Browse the repository at this point in the history
  • Loading branch information
z-huang committed Feb 13, 2022
2 parents a496d47 + cf6e0df commit 9bd72aa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ android {
applicationId "com.zionhuang.music"
minSdkVersion 26
targetSdkVersion 31
versionCode 3
versionName "0.1.2-beta"
versionCode 4
versionName "0.1.3-beta"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
applicationVariants.all { variant ->
Expand Down
6 changes: 3 additions & 3 deletions app/src/main/java/com/zionhuang/music/repos/SongRepository.kt
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.zionhuang.music.repos

import android.app.DownloadManager
import android.app.DownloadManager.Request.VISIBILITY_HIDDEN
import android.util.Log
import androidx.core.content.getSystemService
import androidx.core.net.toUri
Expand All @@ -15,7 +14,9 @@ import com.zionhuang.music.db.daos.DownloadDao
import com.zionhuang.music.db.daos.PlaylistDao
import com.zionhuang.music.db.daos.SongDao
import com.zionhuang.music.db.entities.*
import com.zionhuang.music.extensions.*
import com.zionhuang.music.extensions.TAG
import com.zionhuang.music.extensions.div
import com.zionhuang.music.extensions.getApplication
import com.zionhuang.music.models.ListWrapper
import com.zionhuang.music.models.base.ISortInfo
import com.zionhuang.music.repos.base.LocalRepository
Expand Down Expand Up @@ -90,7 +91,6 @@ object SongRepository : LocalRepository {
.setTitle(song.title)
.setDestinationUri(getSongFile(id).toUri())
.setVisibleInDownloadsUi(false)
.setNotificationVisibility(VISIBILITY_HIDDEN)
val did = downloadManager.enqueue(req)
addDownload(DownloadEntity(did, id))
} catch (e: Exception) {
Expand Down

0 comments on commit 9bd72aa

Please # to comment.