mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-01-11 03:11:50 +00:00
Rate limit 0 effectively disables rate limiting
This commit is contained in:
@@ -123,7 +123,9 @@ func (d *GrabDownloader) download(ctx context.Context, url string, destination s
|
||||
d.log("Error creating new request: %v\n", err)
|
||||
return errors.Wrap(err, url)
|
||||
}
|
||||
req.RateLimiter = rate.NewLimiter(rate.Limit(d.downLimit), int(d.downLimit))
|
||||
if d.downLimit > 0 {
|
||||
req.RateLimiter = rate.NewLimiter(rate.Limit(d.downLimit), int(d.downLimit))
|
||||
}
|
||||
|
||||
d.maybeSetupChecksum(req, expected)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user