From 694351baa83279a7a62958251d9ae1767bdc2ed3 Mon Sep 17 00:00:00 2001 From: RealAngeleno Date: Mon, 10 Jul 2023 03:39:34 -0700 Subject: [PATCH] fix email logic and add nonoko setting to selectbox Changes it so that if the user is mod and they can bypass fields, "email" will show up just fine. If not, "email" will become an options field, like on 4chan. The options field will show up for anybody if hide_email is set to true. Nonoko will be in the selectbox if always_noko is set to true. --- templates/post_form.html | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/templates/post_form.html b/templates/post_form.html index e6d77314..0febce44 100644 --- a/templates/post_form.html +++ b/templates/post_form.html @@ -21,15 +21,20 @@ {% endif %} {% if not config.field_disable_email or (mod and post.mod|hasPermission(config.mod.bypass_field_disable, board.uri)) %} + {% if (mod and not post.mod|hasPermission(config.mod.bypass_field_disable, board.uri) and config.field_email_selectbox) or (not mod and config.field_email_selectbox) or (config.hide_email) %} + {% trans %}Options{% endtrans %} + {% else %} {% trans %}Email{% endtrans %} + {% endif %} {{ antibot.html() }} - {% if config.field_email_selectbox %} + {% if (mod and not post.mod|hasPermission(config.mod.bypass_field_disable, board.uri) and config.field_email_selectbox) or (not mod and config.field_email_selectbox) %} {% else %}