support multiline award notes

pull/136/head
Aevann 2023-02-27 20:17:33 +02:00
parent 1c2e865495
commit 1769c762b0
1 changed files with 3 additions and 1 deletions

View File

@ -216,7 +216,9 @@ def award_thing(v, thing_type, id):
if awarded_coins > 0:
msg += f" and you have received {awarded_coins} coins as a result"
msg += "!"
if note: msg += f"\n\n> {note}"
if note:
note = '\n\n> '.join(note.splitlines())
msg += f"\n\n> {note}"
send_repeatable_notification(author.id, msg)
link = f"[this {thing_type}]({thing.shortlink})"