lib/bugsnag/rack.rb in bugsnag-1.2.5 vs lib/bugsnag/rack.rb in bugsnag-1.2.6

- old
+ new

@@ -1,8 +1,9 @@ require "bugsnag/middleware/rack_request" require "bugsnag/middleware/warden_user" require "bugsnag/middleware/callbacks" +require "bugsnag/middleware/rails3_request" module Bugsnag class Rack def initialize(app) @app = app @@ -20,10 +21,10 @@ Bugsnag.warn("You should set your app's project_root (see https://bugsnag.com/docs/notifiers/ruby#project_root).") end end # Hook up rack-based notification middlewares - config.middleware.use Bugsnag::Middleware::RackRequest if defined?(::Rack) + config.middleware.insert_before(Bugsnag::Middleware::Rails3Request, Bugsnag::Middleware::RackRequest) if defined?(::Rack) config.middleware.use Bugsnag::Middleware::WardenUser if defined?(Warden) end end def call(env) \ No newline at end of file