From b1f64842e83ad4224d94feb269f1b82e29ef79bf Mon Sep 17 00:00:00 2001 From: Aevann Date: Mon, 12 Feb 2024 18:35:39 +0200 Subject: [PATCH] remove unnecessary shit --- files/helpers/actions.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/files/helpers/actions.py b/files/helpers/actions.py index 9abe7b433..34aa9f979 100644 --- a/files/helpers/actions.py +++ b/files/helpers/actions.py @@ -162,14 +162,10 @@ def execute_snappy(post, v): ) g.db.add(award_object) - awarded_coins = int(AWARDS["glowie"]['price'] * COSMETIC_AWARD_COIN_AWARD_PCT) if AWARDS["glowie"]['cosmetic'] else 0 - if AWARDS["glowie"]['cosmetic']: - post.author.pay_account('coins', awarded_coins) + awarded_coins = int(AWARDS["glowie"]['price'] * COSMETIC_AWARD_COIN_AWARD_PCT) + post.author.pay_account('coins', awarded_coins) - msg = f"@Snappy has given [{post.title}]({post.shortlink}) the {AWARDS['glowie']['title']} Award" - if awarded_coins > 0: - msg += f" and you have received {awarded_coins} coins as a result" - msg += "!" + msg = f"@Snappy has given [{post.title}]({post.shortlink}) the Glowie Award and you have received {awarded_coins} coins as a result!" send_repeatable_notification(post.author.id, msg)