Skip to content

Commit

Permalink
fix: fetchTimeOut
Browse files Browse the repository at this point in the history
  • Loading branch information
nugaon committed Dec 21, 2023
1 parent 5f961ff commit cab9ca1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/file/redundancy/getter/strategies.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,9 @@ func GetParamsFromContext(ctx context.Context) (s Strategy, strict bool, fetcher

// SetFetchTimeout sets the timeout for each fetch
func SetFetchTimeout(ctx context.Context, timeout string) context.Context {
if timeout == "" {
timeout = "0"
}
return context.WithValue(ctx, fetcherTimeoutKey{}, timeout)
}

Expand Down

0 comments on commit cab9ca1

Please sign in to comment.