Fix Magic Number problem in DownloadFile (caused by #431).
This commit is contained in:
parent
3e8cf63603
commit
4f70c61592
|
@ -45,7 +45,7 @@ class DownloadFile(
|
||||||
private val mediaStoreService: MediaStoreService
|
private val mediaStoreService: MediaStoreService
|
||||||
private var downloadTask: CancellableTask? = null
|
private var downloadTask: CancellableTask? = null
|
||||||
var isFailed = false
|
var isFailed = false
|
||||||
private var retryCount = 5
|
private var retryCount = MAX_RETRIES
|
||||||
|
|
||||||
private val desiredBitRate: Int = Util.getMaxBitRate(context)
|
private val desiredBitRate: Int = Util.getMaxBitRate(context)
|
||||||
|
|
||||||
|
@ -382,4 +382,8 @@ class DownloadFile(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
companion object {
|
||||||
|
const val MAX_RETRIES = 5
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue