1
0

fix: percentage should be int

This commit is contained in:
オスカー、 2023-03-22 15:01:55 +00:00 committed by GitHub
parent 947bb4fc48
commit 8f159d731d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

2
app.py
View File

@ -137,7 +137,7 @@ async def update_metadata(response: Response, code: str, steam_id: str = Cookie(
if achieve["apiname"] == "go_to_bed":
role.add_or_edit_metadata(key="allperfect", value=True)
success += 1
percentage = (success / total) * 100
percentage = round((success / total) * 100)
role.add_or_edit_metadata(key="percentage", value=percentage)
role.add_or_edit_metadata(key="completed", value=False)
if percentage == 100: