Sha256: afb5ed40dc93c3d9db45e6375d5cb698368337de80c3e57bea96c56c5ba46278
Contents?: true
Size: 531 Bytes
Versions: 12
Compression:
Stored size: 531 Bytes
Contents
module Bugsnag::Middleware ## # Attaches information about current session to an error report class SessionData def initialize(bugsnag) @bugsnag = bugsnag end def call(report) session = Bugsnag::SessionTracker.get_current_session if session && !session[:paused?] if report.unhandled session[:events][:unhandled] += 1 else session[:events][:handled] += 1 end report.session = session end @bugsnag.call(report) end end end
Version data entries
12 entries across 12 versions & 1 rubygems