Merge pull request #741 from Bnyro/master

fix crash when playing video
This commit is contained in:
Bnyro 2022-07-10 09:46:30 +02:00 committed by GitHub
commit 8b82f50c22
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -1032,8 +1032,8 @@ class PlayerFragment : Fragment() {
for (vid in response.videoStreams!!) {
// append quality to list if it has the preferred format (e.g. MPEG)
if (vid.format.equals(videoFormatPreference)) { // preferred format
videosNameArray += vid.quality!!
if (vid.format.equals(videoFormatPreference) && vid.url != null) { // preferred format
videosNameArray += vid.quality.toString()
videosUrlArray += vid.url!!.toUri()
} else if (vid.quality.equals("LBRY") && vid.format.equals("MP4")) { // LBRY MP4 format)
videosNameArray += "LBRY MP4"

View File

@ -30,7 +30,7 @@
android:id="@+id/close_imageButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="5dp"
android:layout_marginEnd="5dp"
android:background="#00FFFFFF"
android:padding="@dimen/exo_icon_padding"
android:src="@drawable/ic_close"