Skip to content

Commit

Permalink
CheckOnly should use a count of 0
Browse files Browse the repository at this point in the history
  • Loading branch information
beautifulentropy committed Feb 29, 2024
1 parent 9e78787 commit 0926b5b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ratelimits/bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,9 @@ func (builder *TransactionBuilder) FailedAuthorizationsPerDomainPerAccountCheckO
}

// Add a check-only transaction for each per domain per account bucket.
txn, err := newCheckOnlyTransaction(limit, perDomainPerAccountBucketKey, 1)
// The cost is 0, as we are only checking that the account and domain
// pair aren't already over the limit.
txn, err := newCheckOnlyTransaction(limit, perDomainPerAccountBucketKey, 0)
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 0926b5b

Please sign in to comment.