Skip to content

Commit 75af3b6

Browse files
committed
use util.CleanPath
1 parent 003d9a0 commit 75af3b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/storage/local.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ func (l *LocalStorage) URL(path, name string) (*url.URL, error) {
130130
func (l *LocalStorage) IterateObjects(prefix string, fn func(path string, obj Object) error) error {
131131
dir := l.dir
132132
if prefix != "" {
133-
dir = filepath.Join(l.dir, prefix)
133+
dir = util.CleanPath(filepath.Join(l.dir, prefix))
134134
if !strings.HasPrefix(dir, strings.TrimSuffix(l.dir, "/")) {
135135
return ErrIllegalPath
136136
}

0 commit comments

Comments
 (0)