moduleFormHelperdefform_errors(model)returnunlessmodel.errors.any?pluralized='error'.pluralize(model.errors.count)headline="The form contains the following #{pluralized}:"content_tag(:div,class: 'alert alert-danger',id: 'error_explanation')docontent_tag(:h4,headline)<<content_tag(:ul)domodel.errors.full_messages.map{|msg|content_tag(:li,msg)}.join.html_safeendendendend