Permalink
Browse files

Use AbstractController error constants

  • Loading branch information...
1 parent 7ee5843 commit 7217d64f615ec064f15c9b2999e98e54997fe67c @josh josh committed Dec 16, 2009
Showing with 2 additions and 3 deletions.
  1. +2 −3 actionpack/lib/action_dispatch/middleware/show_exceptions.rb
@@ -10,8 +10,7 @@ class ShowExceptions
@@rescue_responses = Hash.new(:internal_server_error)
@@rescue_responses.update({
'ActionController::RoutingError' => :not_found,
- # TODO: Clean this up after the switch
- ActionController::UnknownAction.name => :not_found,
+ 'AbstractController::ActionNotFound' => :not_found,
'ActiveRecord::RecordNotFound' => :not_found,
'ActiveRecord::StaleObjectError' => :conflict,
'ActiveRecord::RecordInvalid' => :unprocessable_entity,
@@ -26,7 +25,7 @@ class ShowExceptions
@@rescue_templates.update({
'ActionView::MissingTemplate' => 'missing_template',
'ActionController::RoutingError' => 'routing_error',
- ActionController::UnknownAction.name => 'unknown_action',
+ 'AbstractController::ActionNotFound' => 'unknown_action',
'ActionView::Template::Error' => 'template_error'
})

0 comments on commit 7217d64

Please sign in to comment.