milestone upgrade

subtract pts, rename count to progress, send a chat message on success
This commit is contained in:
2023-03-15 13:13:14 +01:00
parent 54ea10a43c
commit 22501c80c0
3 changed files with 23 additions and 24 deletions
+2 -2
View File
@@ -53,7 +53,7 @@ def handle_redeem(message, user_id):
send_chat(f"Cannot redeem {redeem}, amount of points is not an integer.")
elif int(note) > points:
send_chat(f"Can't redeem {redeem}, you don't have enough points.2")
else:
add_to_milestone(db, redeem, int(note))
elif add_to_milestone(db, user_id, redeem, int(note)):
send_chat(f"Succesfully donated {int(note)} to {redeem} milestone!")
else:
send_chat(f"{redeem} not redeemed, type of redeem not found.")