Remove unnecessary NewApi suppressions.

This commit is contained in:
Isira Seneviratne 2023-04-18 06:10:27 +05:30
parent cf179fd7e9
commit a080526087
4 changed files with 0 additions and 4 deletions

View File

@ -35,7 +35,6 @@ data class Streams(
val uploaderSubscriberCount: Long = 0,
val previewFrames: List<PreviewFrames> = emptyList()
) {
@Suppress("NewApi") // The Paths class is desugared.
fun toDownloadItems(
videoId: String,
fileName: String,

View File

@ -10,6 +10,5 @@ fun Path.toAndroidUriOrNull(): Uri? {
}
fun Path.toAndroidUri(): Uri {
@Suppress("NewApi") // The Path class is desugared.
return toFile().toUri()
}

View File

@ -35,7 +35,6 @@ object DownloadHelper {
}
fun getDownloadDir(context: Context, path: String): Path {
@Suppress("NewApi") // The Path class is desugared.
return getOfflineStorageDir(context).resolve(path).createDirectories()
}

View File

@ -440,7 +440,6 @@ class DownloadService : LifecycleService() {
* Get a [File] from the corresponding download directory and the file name
*/
private fun getDownloadPath(directory: String, fileName: String): Path {
@Suppress("NewApi") // The Path class is desugared.
return DownloadHelper.getDownloadDir(this, directory).resolve(fileName)
}