Skip to content

Conversation

@bonedaddy
Copy link
Collaborator

@bonedaddy bonedaddy commented Aug 18, 2023

notes:

  • basic rolling time periods leveraging BeforeBlock for handling period rollovers

rules.iter_mut().for_each(|rule| {
if rule.flow.is_expired(env.block.time) {
rule.flow.expire(env.block.time, rule.quota.duration);
// is this the correct way to reset the channel value??

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nicolaslara
Copy link

I like this idea

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants