sudara/alonetone

View on GitHub
app/views/shared/_errors.html.erb

Summary

Maintainability
Test Coverage
<% if errors.any? %>
  <div id="error_explanation">
    <h3>
    <% if errors.size == 1 %>
      One minor thing looks off:
    <% else %>
      Please fix the following:
    <% end %>
    </h3>
    <ol>
    <% errors.each do |error| %>
      <li><%= error.full_message %></li>
    <% end %>
    </ol>
  </div>
<% end %>