forked from MarseyWorld/MarseyWorld
fix mbux -> coins
parent
8bd637df57
commit
62e171c09a
|
@ -290,7 +290,12 @@ def transfer_currency(v:User, username:str, currency_name:Literal['coins', 'proc
|
|||
abort(400, f"You don't have enough {friendly_currency_name}")
|
||||
|
||||
if not v.shadowbanned:
|
||||
receiver.coins += amount - tax
|
||||
if currency_name == 'procoins':
|
||||
receiver.procoins += amount - tax
|
||||
elif currency_name == 'coins':
|
||||
receiver.coins += amount - tax
|
||||
else:
|
||||
raise ValueError(f"Invalid currency '{currency_name}' got when transferring {amount} from {v.id} to {receiver.id}")
|
||||
g.db.add(receiver)
|
||||
send_repeatable_notification(GIFT_NOTIF_ID, log_message)
|
||||
send_repeatable_notification(receiver.id, notif_text)
|
||||
|
|
Loading…
Reference in New Issue