From 2301d8cd26c6802c2b6729787c2122c52ea8c201 Mon Sep 17 00:00:00 2001 From: Genadi Samokovarov Date: Sun, 16 Nov 2014 19:19:48 +0200 Subject: Don't show full trace on routing errors Since dbcbbcf2bc58e8971672b143d1c52c0244e33f26 the full trace is shown by default on routing errors. While this is a nice feature to have, it does take the attention off the routes table in this view and I think this is what most of the people look for in this page. Added an exception to the default trace switching rule to remove that noise. --- actionpack/lib/action_dispatch/middleware/debug_exceptions.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb b/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb index 798c087d64..9755d949e7 100644 --- a/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb +++ b/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb @@ -38,7 +38,7 @@ module ActionDispatch traces = wrapper.traces trace_to_show = 'Application Trace' - if traces[trace_to_show].empty? + if traces[trace_to_show].empty? && wrapper.rescue_template != 'routing_error' trace_to_show = 'Full Trace' end -- cgit v1.2.3