Skip to content

Commit

Permalink
Merge pull request #12 from drone/param-name-fix
Browse files Browse the repository at this point in the history
Fixed parameter names in client retry func
marko-gacesa authored Jun 24, 2021

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
2 parents 533eebe + 9e4cc46 commit 2f5cff3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client/http.go
Original file line number Diff line number Diff line change
@@ -201,9 +201,9 @@ func (p *HTTPClient) Upload(ctx context.Context, step int64, lines []*drone.Line
return err
}

func (p *HTTPClient) retry(ctx context.Context, method, path string, in, out interface{}) (*http.Response, error) {
func (p *HTTPClient) retry(ctx context.Context, path, method string, in, out interface{}) (*http.Response, error) {
for {
res, err := p.do(ctx, method, path, in, out)
res, err := p.do(ctx, path, method, in, out)
// do not retry on Canceled or DeadlineExceeded
if err := ctx.Err(); err != nil {
p.logger().Tracef("http: context canceled")

0 comments on commit 2f5cff3

Please sign in to comment.