From ba267224077806a0ba8609cbb87ac402ffff6dc7 Mon Sep 17 00:00:00 2001 From: kreegahbundolo Date: Thu, 10 Sep 2020 06:58:59 +0200 Subject: [PATCH] Fix for email send issue (#1640) * Fix issue with sending wrong API parameter for email sending in Admin Panel --- CTFd/forms/email.py | 2 +- CTFd/themes/admin/templates/modals/mail/send.html | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CTFd/forms/email.py b/CTFd/forms/email.py index 93cb2ba6..889cfac0 100644 --- a/CTFd/forms/email.py +++ b/CTFd/forms/email.py @@ -6,5 +6,5 @@ from CTFd.forms.fields import SubmitField class SendEmailForm(BaseForm): - message = TextAreaField("Message", validators=[InputRequired()]) + text = TextAreaField("Message", validators=[InputRequired()]) submit = SubmitField("Send") diff --git a/CTFd/themes/admin/templates/modals/mail/send.html b/CTFd/themes/admin/templates/modals/mail/send.html index 8971a0bd..621ba8f8 100644 --- a/CTFd/themes/admin/templates/modals/mail/send.html +++ b/CTFd/themes/admin/templates/modals/mail/send.html @@ -1,12 +1,12 @@ {% with form = Forms.email.SendEmailForm() %}
- {{ form.message.label }} - {{ form.message(class="form-control", rows="15") }} + {{ form.text.label }} + {{ form.text(class="form-control", rows="15") }}
{{ form.submit(class="btn btn-primary float-right") }}
-{% endwith %} \ No newline at end of file +{% endwith %}