[Android] Ensure options delegate is initialized
Geoffrey Métais
git at videolan.org
Thu Dec 20 15:50:20 CET 2018
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu Dec 20 15:49:49 2018 +0100| [3355317c1450c49c36a59d8c63e5346491d565c3] | committer: Geoffrey Métais
Ensure options delegate is initialized
> https://code.videolan.org/videolan/vlc-android/commit/3355317c1450c49c36a59d8c63e5346491d565c3
---
vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt b/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt
index 522f6331b..fc1ce496e 100644
--- a/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt
+++ b/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt
@@ -460,7 +460,7 @@ class AudioPlayer : androidx.fragment.app.Fragment(), PlaylistAdapter.IPlayer, T
override fun onDestroy() {
super.onDestroy()
- optionsDelegate.release()
+ if (this::optionsDelegate.isInitialized) optionsDelegate.release()
playlistModel.dataset.removeObserver(playlistObserver)
playlistModel.onCleared()
}
More information about the Android
mailing list