Permalink
Browse files

add help text to routing error

When a newcomer hits the routing error page they
are often confused about how to trouble shoot the
next step. Adding a simple help text can gently 
remind coders where to get more help.
  • Loading branch information...
1 parent 7bde2e2 commit 921dcc2570b34e48a5f3eef9e0ef3044488f81d3 @schneems schneems committed Dec 17, 2011
Showing with 13 additions and 8 deletions.
  1. +13 −8 actionpack/lib/action_dispatch/middleware/templates/rescues/routing_error.erb
@@ -1,10 +1,15 @@
<h1>Routing Error</h1>
<p><pre><%=h @exception.message %></pre></p>
-<% unless @exception.failures.empty? %><p>
- <h2>Failure reasons:</h2>
- <ol>
- <% @exception.failures.each do |route, reason| %>
- <li><code><%=h route.inspect.gsub('\\', '') %></code> failed because <%=h reason.downcase %></li>
- <% end %>
- </ol>
-</p><% end %>
+<% unless @exception.failures.empty? %>
+ <p>
+ <h2>Failure reasons:</h2>
+ <ol>
+ <% @exception.failures.each do |route, reason| %>
+ <li><code><%=h route.inspect.gsub('\\', '') %></code> failed because <%=h reason.downcase %></li>
+ <% end %>
+ </ol>
+ </p>
+<% end %>
+<p>
+ Try running <code>rake routes</code> for more information on available routes.
+</p>

0 comments on commit 921dcc2

Please sign in to comment.