Skip to content

Commit 5750961

Browse files
authored
Merge pull request #347 from drone/fix/github-path-escaping
fix: Prevent the client from un-escaping the encoded path parameters only for github
2 parents 4b9ccaa + 3e0fb7d commit 5750961

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scm/client.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ func (c *Client) Do(ctx context.Context, in *Request) (*Response, error) {
170170
}
171171
// hack to prevent the client from un-escaping the
172172
// encoded github path parameters when parsing the url.
173-
if strings.Contains(in.Path, "%2F") {
173+
if strings.Contains(in.Path, "%2F") && c.Driver == DriverGithub {
174174
req.URL.Opaque = strings.Split(req.URL.RawPath, "?")[0]
175175
}
176176

0 commit comments

Comments
 (0)