From ae68eecb653ae2522f901bf098df416aa033a5ec Mon Sep 17 00:00:00 2001 From: freamon Date: Fri, 31 May 2024 21:10:09 +0100 Subject: [PATCH] Only duplicate title into body for Polls if it's not already in there --- app/community/util.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/community/util.py b/app/community/util.py index 013ed9c7..310e0059 100644 --- a/app/community/util.py +++ b/app/community/util.py @@ -426,7 +426,7 @@ def save_post(form, post: Post, type: str): elif type == 'poll': post.title = form.poll_title.data - post.body = form.poll_title.data + '\n' + form.poll_body.data + post.body = form.poll_title.data + '\n' + form.poll_body.data if post.title not in form.poll_body.data else form.poll_body.data post.body_html = markdown_to_html(post.body) post.type = POST_TYPE_POLL else: