diff --git a/fs/accounting/token_bucket.go b/fs/accounting/token_bucket.go index a306096e8..a8b4bcd2d 100644 --- a/fs/accounting/token_bucket.go +++ b/fs/accounting/token_bucket.go @@ -41,7 +41,12 @@ type tokenBucket struct { // // Call with lock held func (bs *buckets) _isOff() bool { //nolint:unused // Don't include unused when running golangci-lint in case its on windows where this is not called - return bs[0] == nil + for i := range bs { + if bs[i] != nil { + return false + } + } + return true } // Disable the limits