diff --git a/app/src/main/java/com/github/libretube/fragments/PlayerFragment.kt b/app/src/main/java/com/github/libretube/fragments/PlayerFragment.kt index d919209a0..eff82fe5f 100644 --- a/app/src/main/java/com/github/libretube/fragments/PlayerFragment.kt +++ b/app/src/main/java/com/github/libretube/fragments/PlayerFragment.kt @@ -1196,9 +1196,10 @@ class PlayerFragment : Fragment() { val defRes = PreferenceHelper.getString( requireContext(), "default_resolution", - "auto" + "hls" )!! - if (defRes != "auto") { + + if (defRes != "hls") { videosNameArray.forEachIndexed { index, pipedStream -> // search for quality preference in the available stream sources if (pipedStream.contains(defRes)) { @@ -1210,6 +1211,7 @@ class PlayerFragment : Fragment() { } } } + // if default resolution isn't set or available, use hls if available if (streams.hls != null) { val mediaItem: MediaItem = MediaItem.Builder() diff --git a/app/src/main/res/values/array.xml b/app/src/main/res/values/array.xml index 6c7eac38c..119e84cdc 100644 --- a/app/src/main/res/values/array.xml +++ b/app/src/main/res/values/array.xml @@ -583,7 +583,7 @@ 144p - + hls 1080p 720p 480p