Sha256: a5ce41665e704a6f188701a7a00a173bfecdb0c2a9e6c18e306a93cd6a02fb02

Contents?: true

Size: 518 Bytes

Versions: 102

Compression:

Stored size: 518 Bytes

Contents

module Bugsnag::Middleware
  class Callbacks
    def initialize(bugsnag)
      @bugsnag = bugsnag
    end

    def call(notification)
      if notification.request_data[:before_callbacks]
        notification.request_data[:before_callbacks].each {|c| c.call(*[notification][0...c.arity]) }
      end

      @bugsnag.call(notification)

      if notification.request_data[:after_callbacks]
        notification.request_data[:after_callbacks].each {|c| c.call(*[notification][0...c.arity]) }
      end
    end
  end
end

Version data entries

102 entries across 102 versions & 2 rubygems

Version Path
bugsnag-5.5.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.4.1 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.4.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.3.3 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.3.2 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.3.1 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.3.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.2.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.1.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.0.1 lib/bugsnag/middleware/callbacks.rb
bugsnag-5.0.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-4.2.1 lib/bugsnag/middleware/callbacks.rb
bugsnag-4.2.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-4.1.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-4.0.2 lib/bugsnag/middleware/callbacks.rb
bugsnag-4.0.1 lib/bugsnag/middleware/callbacks.rb
bugsnag-4.0.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-3.0.0 lib/bugsnag/middleware/callbacks.rb
bugsnag-2.8.13 lib/bugsnag/middleware/callbacks.rb
bugsnag-maglev--2.8.12 lib/bugsnag/middleware/callbacks.rb