fix: 按单次取件过期问题

This commit is contained in:
lan
2024-01-11 17:51:05 +08:00
parent c6e0d3282a
commit 4e9d859ab0
3 changed files with 5 additions and 7 deletions
+1 -1
View File
@@ -33,7 +33,7 @@ class FileCodes(Model):
return self.expired_at < await get_now()
# 按次数
else:
return self.expired_count != -1 and self.expired_count == 0
return self.expired_count <= 0
async def get_file_path(self):
return f"{self.file_path}/{self.uuid_file_name}"