From 3171fce76bd8209a4b8ba52e93118b2c8d1972ab Mon Sep 17 00:00:00 2001 From: Peter Guntrip Date: Mon, 5 Dec 2016 11:53:38 +0000 Subject: [PATCH] Set view's error procedure to remove field_with_errors div - the field_with_errors div was causing an issue with the javascript for the new GOVUK style radio/checkboxes and was therefore not highlighting element which had an error in a form --- config/application.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/application.rb b/config/application.rb index c89948b2c..91ea7d171 100644 --- a/config/application.rb +++ b/config/application.rb @@ -23,5 +23,9 @@ class Application < Rails::Application config.middleware.use BounceBrowserconfig config.mount_javascript_test_routes = false + + config.action_view.field_error_proc = proc { |html_tag, _| + html_tag + } end end