mirror of
https://github.com/libre-tube/LibreTube.git
synced 2024-12-13 22:00:30 +05:30
Merge pull request #3318 from Isira-Seneviratne/updateParameters_inline
Convert updateParameters() to an inline function.
This commit is contained in:
commit
a552004df1
@ -2,9 +2,6 @@ package com.github.libretube.extensions
|
||||
|
||||
import com.google.android.exoplayer2.trackselection.DefaultTrackSelector
|
||||
|
||||
fun DefaultTrackSelector.updateParameters(
|
||||
inline fun DefaultTrackSelector.updateParameters(
|
||||
actions: DefaultTrackSelector.Parameters.Builder.() -> Unit
|
||||
) = apply {
|
||||
val params = buildUponParameters().apply(actions)
|
||||
setParameters(params)
|
||||
}
|
||||
) = setParameters(buildUponParameters().apply(actions))
|
||||
|
Loading…
Reference in New Issue
Block a user