Sha256: 053d42fbe959fe9dce1bda1e77f7f1fb87d62ea1a437798ed283c5f349dcb75d

Contents?: true

Size: 351 Bytes

Versions: 1

Compression:

Stored size: 351 Bytes

Contents

module Bugsnag
  class Rack
    def initialize(app)
      @app = app
    end

    def call(env)
      begin
        response = @app.call(env)
      rescue Exception => raised
        Bugsnag.notify(raised)
        raise
      end

      if env["rack.exception"]
        Bugsnag.notify(env["rack.exception"])
      end

      response
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bugsnag-1.0.0 lib/bugsnag/rack.rb