Class: ExceptionHandler::Parser::Data
- Inherits:
-
Object
- Object
- ExceptionHandler::Parser::Data
- Defined in:
- lib/exception_handler/parser/data.rb
Instance Attribute Summary collapse
-
#controller ⇒ Object
readonly
Data.
-
#exception ⇒ Object
readonly
Data.
-
#request ⇒ Object
readonly
Data.
Class Method Summary collapse
Instance Attribute Details
#controller ⇒ Object (readonly)
Data
6 7 8 |
# File 'lib/exception_handler/parser/data.rb', line 6 def controller @controller end |
#exception ⇒ Object (readonly)
Data
6 7 8 |
# File 'lib/exception_handler/parser/data.rb', line 6 def exception @exception end |
#request ⇒ Object (readonly)
Data
6 7 8 |
# File 'lib/exception_handler/parser/data.rb', line 6 def request @request end |
Class Method Details
.create(exception, request, controller) ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/exception_handler/parser/data.rb', line 10 def create exception, request, controller @exception = exception @request = request @controller = controller #http://blog.habanerohq.com/post/16800611137/selectively-silence-activerecord-logging = "" Rails.logger.silence do #-> stops Error.create from showing output ExceptionHandler::Error.create info do |error| += "\n======================\n" += "#{error.class_name}:\n" += "\n#{error.}\n" += Rails.backtrace_cleaner.clean(error.trace.split("\n")).join("\n") += "\n======================\n" end end Rails.logger.fatal unless .blank? end |