[Android] OTG access: Fix logic fail
Geoffrey Métais
git at videolan.org
Fri Feb 21 14:34:15 CET 2020
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Wed Feb 19 11:39:13 2020 +0100| [811e00fa4706807d6ec1ee6ab8905413288cec48] | committer: Geoffrey Métais
OTG access: Fix logic fail
> https://code.videolan.org/videolan/vlc-android/commit/811e00fa4706807d6ec1ee6ab8905413288cec48
---
.../src/org/videolan/vlc/providers/FileBrowserProvider.kt | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/application/vlc-android/src/org/videolan/vlc/providers/FileBrowserProvider.kt b/application/vlc-android/src/org/videolan/vlc/providers/FileBrowserProvider.kt
index 997ac66c1..5c71fd66d 100644
--- a/application/vlc-android/src/org/videolan/vlc/providers/FileBrowserProvider.kt
+++ b/application/vlc-android/src/org/videolan/vlc/providers/FileBrowserProvider.kt
@@ -35,15 +35,15 @@ import org.videolan.medialibrary.MLServiceLocator
import org.videolan.medialibrary.interfaces.media.MediaWrapper
import org.videolan.medialibrary.media.DummyItem
import org.videolan.medialibrary.media.MediaLibraryItem
+import org.videolan.resources.AndroidDevices
+import org.videolan.tools.livedata.LiveDataset
import org.videolan.vlc.ExternalMonitor
import org.videolan.vlc.R
import org.videolan.vlc.gui.helpers.hf.StoragePermissionsDelegate
import org.videolan.vlc.gui.helpers.hf.getDocumentFiles
import org.videolan.vlc.repository.BrowserFavRepository
import org.videolan.vlc.repository.DirectoryRepository
-import org.videolan.resources.AndroidDevices
import org.videolan.vlc.util.FileUtils
-import org.videolan.tools.livedata.LiveDataset
import org.videolan.vlc.util.convertFavorites
import java.io.File
@@ -179,7 +179,7 @@ open class FileBrowserProvider(
}
override fun onChanged(list: MutableList<UsbDevice>?) {
- if (!list.isNullOrEmpty()) {
+ if (list.isNullOrEmpty()) {
if (otgPosition != -1) {
dataset.remove(otgPosition)
otgPosition = -1
More information about the Android
mailing list