Skip to content

Commit

Permalink
Leftovers
Browse files Browse the repository at this point in the history
  • Loading branch information
euri10 committed Jun 21, 2021
1 parent 8125abe commit 074a576
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions ratelimit/backends/slidingredis.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,6 @@ async def retry_after(self, path: str, user: str, rule: Rule) -> bool:
block_time = await self.is_blocking(user)
if block_time > 0:
return block_time
# if await self.is_blocking(user):
# assert rule.block_time
# return False, {
# "expire_in": [rule.block_time],
# "scores": [],
# "epoch": time.time(),
# }

limits = await self.get_limits(path, user, rule)
retry_after = limits["expire_in"][0] if not all(limits["scores"]) else 0
Expand Down

0 comments on commit 074a576

Please sign in to comment.