mirror of
https://github.com/logos-messaging/logos-messaging-nim.git
synced 2026-01-07 08:23:08 +00:00
fix: comment
This commit is contained in:
parent
340b82f7b6
commit
7c0701ef83
@ -109,10 +109,11 @@ proc update(bucket: TokenBucket, currentTime: Moment) =
|
||||
else:
|
||||
updateStrict(bucket, currentTime)
|
||||
|
||||
## Returns the available capacity of the bucket: (budget, budgetCap)
|
||||
proc getAvailableCapacity*(
|
||||
bucket: TokenBucket, currentTime: Moment = Moment.now()
|
||||
): tuple[budget: int, budgetCap: int] =
|
||||
## Returns the available capacity of the bucket: (budget, budgetCap)
|
||||
|
||||
if periodElapsed(bucket, currentTime):
|
||||
case bucket.replenishMode
|
||||
of ReplenishMode.Strict:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user