From db0dd4be9e45183b856e313333ac3a2fa990ac76 Mon Sep 17 00:00:00 2001 From: Graeme Porteous Date: Mon, 22 Apr 2024 16:00:49 +0100 Subject: [PATCH] Update contact form error handling Rescue from missing contact params which can happen when spammers attempt to use our forms - probably via scripts or automated actions. Fixes #8212 --- app/controllers/help_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/help_controller.rb b/app/controllers/help_controller.rb index 4dfb5877a6..6796bfe0c7 100644 --- a/app/controllers/help_controller.rb +++ b/app/controllers/help_controller.rb @@ -13,7 +13,7 @@ class HelpController < ApplicationController ContactSpamError = Class.new(StandardError) - rescue_from ContactSpamError do + rescue_from ContactSpamError, ActionController::ParameterMissing do redirect_to frontpage_url end