trim the slash from the end of selected paths
This commit is contained in:
parent
343bca34a7
commit
411081ba98
1 changed files with 2 additions and 3 deletions
|
@ -21,7 +21,6 @@ import com.simplemobiletools.commons.views.RecyclerViewDivider
|
|||
import kotlinx.android.synthetic.main.dialog_filepicker.view.*
|
||||
import java.io.File
|
||||
import java.util.*
|
||||
import kotlin.comparisons.compareBy
|
||||
|
||||
/**
|
||||
* The only filepicker constructor with a couple optional parameters
|
||||
|
@ -106,7 +105,7 @@ class FilePickerDialog(val activity: BaseSimpleActivity,
|
|||
|
||||
private fun createNewFolder() {
|
||||
CreateNewFolderDialog(activity, currPath) {
|
||||
callback.invoke(it)
|
||||
callback.invoke(it.trimEnd('/'))
|
||||
mDialog.dismiss()
|
||||
}
|
||||
}
|
||||
|
@ -154,7 +153,7 @@ class FilePickerDialog(val activity: BaseSimpleActivity,
|
|||
}
|
||||
|
||||
private fun sendSuccess() {
|
||||
callback.invoke(currPath)
|
||||
callback.invoke(currPath.trimEnd('/'))
|
||||
mDialog.dismiss()
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue