Skip to content

Commit 055c9ac

Browse files
authored
Force url encode space with '%20' and not '+' (#140)
1 parent ce22bf2 commit 055c9ac

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

pkg/dataplane/http/context.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,9 @@ func (c *context) GetContainerContentsSync(getContainerContentsInput *v3io.GetCo
198198
var queryBuilder strings.Builder
199199
if getContainerContentsInput.Path != "" {
200200
queryBuilder.WriteString("prefix=")
201-
queryBuilder.WriteString(url.QueryEscape(getContainerContentsInput.Path))
201+
encodedPrefix := url.QueryEscape(getContainerContentsInput.Path)
202+
encodedPrefix = strings.Replace(encodedPrefix, "+", "%20", -1)
203+
queryBuilder.WriteString(encodedPrefix)
202204
}
203205

204206
if getContainerContentsInput.DirectoriesOnly {

0 commit comments

Comments
 (0)