Skip to content

Commit

Permalink
Update api.go
Browse files Browse the repository at this point in the history
Co-authored-by: Victor Elias <victorgelias@gmail.com>
Signed-off-by: Rafał Leszko <rafal@livepeer.org>
  • Loading branch information
leszko and victorges committed Mar 25, 2024
1 parent 03b5d09 commit e7cb002
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions api.go
Original file line number Diff line number Diff line change
Expand Up @@ -915,10 +915,8 @@ func (lapi *Client) LockPull(id string, leaseTimeoutMs time.Duration) error {
return errors.New("empty id")
}

payload := struct {
leaseTimeout time.Duration
}{
leaseTimeout: leaseTimeoutMs,
payload := map[string]interface{}{
"leaseTimeout": leaseTimeoutMs,
}
u := fmt.Sprintf("%s/api/stream/%s/lockPull", lapi.chosenServer, id)
err := lapi.doRequest("POST", u, "stream", "lock_pull", payload, nil)
Expand Down

0 comments on commit e7cb002

Please sign in to comment.