Skip to content

Commit

Permalink
Don't squawk RoutingErrors, v.1.0.3
Browse files Browse the repository at this point in the history
A routing error is just a 404 and we'd prefer not to hear about
it. This could be a configurable setting in the future.
  • Loading branch information
robheittman committed Nov 14, 2012
1 parent 6f0d492 commit 79ad628
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
8 changes: 6 additions & 2 deletions lib/appygram-rails/integration/rack_rails.rb
Expand Up @@ -12,12 +12,16 @@ def call(env)
begin
body = @app.call(env)
rescue Exception => e
::AppygramRails::Catcher.handle_with_controller(e,env['action_controller.instance'], Rack::Request.new(env))
unless e.is_a? ActionController::RoutingError
::AppygramRails::Catcher.handle_with_controller(e,env['action_controller.instance'], Rack::Request.new(env))
end
raise
end

if env['rack.exception']
::AppygramRails::Catcher.handle_with_controller(env['rack.exception'],env['action_controller.instance'], Rack::Request.new(env))
unless env['rack.exception'].is_a? ActionController::RoutingError
::AppygramRails::Catcher.handle_with_controller(env['rack.exception'],env['action_controller.instance'], Rack::Request.new(env))
end
end

body
Expand Down
2 changes: 1 addition & 1 deletion lib/appygram-rails/version.rb
@@ -1,3 +1,3 @@
module AppygramRails
VERSION = '1.0.2'
VERSION = '1.0.3'
end

0 comments on commit 79ad628

Please sign in to comment.