1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Fix examples in ActiveSupport::LogSubscriber docs

[ci skip]
This commit is contained in:
Gannon McGibbon 2018-12-31 15:17:40 -05:00
parent 710e0ffc5a
commit 1b402a510a

View file

@ -16,7 +16,7 @@ module ActiveSupport
# module ActiveRecord
# class LogSubscriber < ActiveSupport::LogSubscriber
# def sql(event)
# "#{event.payload[:name]} (#{event.duration}) #{event.payload[:sql]}"
# info "#{event.payload[:name]} (#{event.duration}) #{event.payload[:sql]}"
# end
# end
# end
@ -47,8 +47,8 @@ module ActiveSupport
# if exception
# exception_object = event.payload[:exception_object]
#
# "[ERROR] #{event.payload[:name]}: #{exception.join(', ')} " \
# "(#{exception_object.backtrace.first})"
# error "[ERROR] #{event.payload[:name]}: #{exception.join(', ')} " \
# "(#{exception_object.backtrace.first})"
# else
# # standard logger code
# end