Skip to content

Commit

Permalink
♻️ refactor: replace deprecated per_second with `seconds_per_reques…
Browse files Browse the repository at this point in the history
…t` in rate-limiting middleware code (#616)
  • Loading branch information
jurijsb authored Oct 6, 2024
1 parent c796ae8 commit 959d0c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ pub fn run(
.wrap(cors)
.wrap(Governor::new(
&GovernorConfigBuilder::default()
.per_second(config.rate_limiter.time_limit as u64)
.seconds_per_request(config.rate_limiter.time_limit as u64)
.burst_size(config.rate_limiter.number_of_requests as u32)
.finish()
.unwrap(),
Expand Down

0 comments on commit 959d0c5

Please sign in to comment.