Module: AmazingPrint::Logger
- Defined in:
- lib/amazing_print/core_ext/logger.rb
Instance Method Summary collapse
-
#ap(object, options = {}) ⇒ Object
Add ap method to logger ——————————————————————————.
Instance Method Details
#ap(object, options = {}) ⇒ Object
Add ap method to logger
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/amazing_print/core_ext/logger.rb', line 12 def ap(object, = {}) if .is_a?(Hash) level = .delete(:level) else level = = {} end level ||= AmazingPrint.defaults[:log_level] if AmazingPrint.defaults level ||= :debug send level, object.ai() end |