[Android] Fix NullPointerException
Nicolas Pomepuy
git at videolan.org
Tue Sep 7 07:36:38 UTC 2021
vlc-android | branch: master | Nicolas Pomepuy <nicolas at videolabs.io> | Mon Sep 6 11:30:37 2021 +0200| [7ae6b20cdd6ec3574ff394111a16b4be004ccf77] | committer: Nicolas Pomepuy
Fix NullPointerException
> https://code.videolan.org/videolan/vlc-android/commit/7ae6b20cdd6ec3574ff394111a16b4be004ccf77
---
application/vlc-android/src/org/videolan/vlc/gui/helpers/ImageLoader.kt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/vlc-android/src/org/videolan/vlc/gui/helpers/ImageLoader.kt b/application/vlc-android/src/org/videolan/vlc/gui/helpers/ImageLoader.kt
index 0d34b17d5..e2b3c4473 100644
--- a/application/vlc-android/src/org/videolan/vlc/gui/helpers/ImageLoader.kt
+++ b/application/vlc-android/src/org/videolan/vlc/gui/helpers/ImageLoader.kt
@@ -208,7 +208,7 @@ fun downloadIcon(v: View, imageUrl: String?, tv: Boolean = true) {
}
@BindingAdapter("missingMedia")
-fun missingMedia(imageView: ImageView, media: MediaLibraryItem) {
+fun missingMedia(imageView: ImageView, media: MediaLibraryItem?) {
if (media is VideoGroup && !media.isNetwork()) imageView.setImageResource(R.drawable.ic_sd_media_off) else imageView.setImageResource(R.drawable.ic_network_media_off)
}
More information about the Android
mailing list