commit 6df1449
delthas
·
2025-12-23 14:54:08 +0000 UTC
parent 9eed830
Fix UPLOAD autocompletions for relative paths
1 files changed,
+2,
-1
+2,
-1
1@@ -206,10 +206,11 @@ func (app *App) completionsUpload(cs []ui.Completion, cursorIdx int, text []rune
2 dirPath = "/"
3 }
4 } else {
5+ isDir := strings.HasSuffix(path, string(filepath.Separator))
6 if home != "" && !filepath.IsAbs(path) {
7 path = filepath.Join(home, path)
8 }
9- if strings.HasSuffix(path, string(filepath.Separator)) {
10+ if isDir {
11 dirPath = path
12 } else {
13 dirPath = filepath.Dir(path)