Sha256: 823aff2d5096bb12cb601e89cb3957a89be02389a36c8d9228858da9f830ac65

Contents?: true

Size: 504 Bytes

Versions: 4

Compression:

Stored size: 504 Bytes

Contents

module ExceptionHandler
  class ExceptionMailer < ActionMailer::Base

      # Layout
      layout "mailers/layouts/mailer"

      # Defaults
      default from: 			    ExceptionHandler.config.email
      default template_path: 	"exception_handler/mailers" # => http://stackoverflow.com/a/18579046/1143732

      def new_exception e
      	@exception = e
        mail to: ExceptionHandler.config.email
        Rails.logger.info "Exception Sent To → #{ExceptionHandler.config.email}"
      end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
exception_handler-0.7.6.0 app/mailers/exception_handler/exception_mailer.rb
exception_handler-0.7.5.15 app/mailers/exception_handler/exception_mailer.rb
exception_handler-0.7.5 app/mailers/exception_handler/exception_mailer.rb
exception_handler-0.7.0 app/mailers/exception_handler/exception_mailer.rb