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
  • Loading branch information
marko-gacesa authored Jun 24, 2021
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
Expand Up @@ -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")
Expand Down

0 comments on commit 2f5cff3

Please sign in to comment.