mirror of
https://github.com/austinried/subtracks.git
synced 2026-11-10 15:11:58 +01:00
drop unnecessary null checks flagged by the compiler
This commit is contained in:
@@ -140,9 +140,9 @@ class SourceRepository(
|
||||
// quality rather than the original that would then have to be transcoded on every play.
|
||||
val quality = downloadQuality
|
||||
return if (quality.transcodes) {
|
||||
source.streamUri(songId, quality.maxBitrate, quality.format)?.toString()
|
||||
source.streamUri(songId, quality.maxBitrate, quality.format).toString()
|
||||
} else {
|
||||
source.downloadUri(songId)?.toString()
|
||||
source.downloadUri(songId).toString()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -84,7 +84,7 @@ class SourceRepositoryTest {
|
||||
}
|
||||
|
||||
assertTrue(transcoded!!.contains("maxBitRate=128"))
|
||||
assertTrue(transcoded!!.contains("format=opus"))
|
||||
assertTrue(transcoded.contains("format=opus"))
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user