This commit is contained in:
Lan
2024-09-24 20:25:34 +08:00
parent 0dca661508
commit 83598956a1
+1 -1
View File
@@ -19,7 +19,7 @@ class IPRateLimit:
def check_ip(self, ip):
# 检查ip是否被禁止
if ip in self.ips:
if self.ips[ip]['count'] >= self.count:
if int(self.ips[ip]['count']) >= int(self.count):
if self.ips[ip]['time'] + timedelta(minutes=self.minutes) > datetime.now():
return False
else: