class UniformNotifier::BugsnagNotifier

Public Class Methods

active?() click to toggle source
# File lib/uniform_notifier/bugsnag.rb, line 3
def self.active?
  !!UniformNotifier.bugsnag
end

Protected Class Methods

_out_of_channel_notify(data) click to toggle source
# File lib/uniform_notifier/bugsnag.rb, line 9
def self._out_of_channel_notify(data)
  opt = {}
  if UniformNotifier.bugsnag.is_a?(Hash)
    opt = UniformNotifier.bugsnag
  end

  exception = Exception.new(data[:title])
  exception.set_backtrace(data[:backtrace]) if data[:backtrace]
  Bugsnag.notify(exception, opt.merge(
    :grouping_hash => data[:body] || data[:title],
    :notification => data
  ))
end