add OTG path to the included paths initially

This commit is contained in:
tibbi 2019-02-20 16:56:16 +01:00
parent 1ed6176f0d
commit 4b546b6d52

View file

@ -375,7 +375,9 @@ class MainActivity : SimpleActivity(), DirectoryOperationsListener {
if (!config.wasOTGHandled && hasPermission(PERMISSION_WRITE_STORAGE) && hasOTGConnected() && config.OTGPath.isEmpty()) {
config.wasOTGHandled = true
getStorageDirectories().firstOrNull { it.trimEnd('/') != internalStoragePath && it.trimEnd('/') != sdCardPath }?.apply {
config.OTGPath = trimEnd('/')
val otgPath = trimEnd('/')
config.OTGPath = otgPath
config.addIncludedFolder(otgPath)
}
}
}.start()