mirror of
https://github.com/actix/actix-extras.git
synced 2025-02-20 01:34:22 +01:00
fix: remove dbg
This commit is contained in:
parent
453d609e6b
commit
0a70071c02
@ -140,10 +140,10 @@ impl Limiter {
|
|||||||
|
|
||||||
/// Consumes one rate limit unit, returning the status.
|
/// Consumes one rate limit unit, returning the status.
|
||||||
pub async fn count(&self, key: impl Into<String>) -> Result<Status, Error> {
|
pub async fn count(&self, key: impl Into<String>) -> Result<Status, Error> {
|
||||||
let (count, reset) = dbg!(self.track(key).await?);
|
let (count, reset) = self.track(key).await?;
|
||||||
let status = Status::new(count, self.limit, reset);
|
let status = Status::new(count, self.limit, reset);
|
||||||
|
|
||||||
if dbg!(count) > dbg!(self.limit) {
|
if count > self.limit {
|
||||||
Err(Error::LimitExceeded(status))
|
Err(Error::LimitExceeded(status))
|
||||||
} else {
|
} else {
|
||||||
Ok(status)
|
Ok(status)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user