From fdaa4ebdd1e54fadaa48d8bdb395538b739a7f53 Mon Sep 17 00:00:00 2001 From: Your Name Date: Tue, 12 Sep 2023 02:04:38 +0200 Subject: [PATCH] better error --- inc/config.php | 1 + post.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/inc/config.php b/inc/config.php index 05e90f1d..47709ea6 100644 --- a/inc/config.php +++ b/inc/config.php @@ -1182,6 +1182,7 @@ $config['error']['nopost'] = _('You didn\'t make a post.'); $config['error']['flood'] = _('Flood detected; Post discarded.'); $config['error']['spam'] = _('Your request looks automated; Post discarded.'); + $config['error']['simple_spam'] = _('You must answer the question to make a new thread. See the last field.'); $config['error']['unoriginal'] = _('Unoriginal content!'); $config['error']['muted'] = _('Unoriginal content! You have been muted for %d seconds.'); $config['error']['youaremuted'] = _('You are muted! Expires in %d seconds.'); diff --git a/post.php b/post.php index b092a20e..ee652a18 100644 --- a/post.php +++ b/post.php @@ -485,7 +485,7 @@ function handle_post(){ if (isset($config['simple_spam']) && $post['op']) { if(!isset($_POST['simple_spam']) || $config['simple_spam']['answer'] != $_POST['simple_spam']){ - error($config['error']['spam']); + error($config['error']['simple_spam']); } }