module ExceptionNotification

Public Class Methods

initialize() click to toggle source
# File lib/exception_notification.rb, line 19
  def self.initialize
    if defined?(ActionController::Base)
      ActionController::Base.send(:include, ExceptionNotification::ExceptionNotifiable)
    end

#TODO: Set this in gobal SEN config as the logger like they do in HoptoadNotifier
#    rails_logger = if defined?(::Rails.logger)
#                     ::Rails.logger
#                   elsif defined?(RAILS_DEFAULT_LOGGER)
#                     RAILS_DEFAULT_LOGGER
#                   end
#    HoptoadNotifier.configure(true) do |config|
#      config.logger = rails_logger
#      config.environment_name = RAILS_ENV  if defined?(RAILS_ENV)
#      config.project_root     = RAILS_ROOT if defined?(RAILS_ROOT)
#      config.framework        = "Rails: #{::Rails::VERSION::STRING}" if defined?(::Rails::VERSION)
#    end
  end