<% if @email_message.errors.any? %>
  $("#email_mess_div").html("<%= escape_javascript(render '/shared/errors_list', error_object: @email_message) %>");
<% else %>
  document.getElementById("contact_form_form").reset();
  $("#email_mess_div").html("<%= escape_javascript(render '/home/message_sent_info') %>");
<% end %>
