diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2009-11-11 01:43:58 -0800 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2009-11-11 01:43:58 -0800 |
commit | fca32eb6c5b41e4f19a25b7b246c4a8a3d763667 (patch) | |
tree | 7fdb9e32b743aeb254854371349cecfd2499defa | |
parent | 322b6b29c272aa6c9b9d2556b736dbe32db3aa45 (diff) | |
download | rails-fca32eb6c5b41e4f19a25b7b246c4a8a3d763667.tar.gz rails-fca32eb6c5b41e4f19a25b7b246c4a8a3d763667.tar.bz2 rails-fca32eb6c5b41e4f19a25b7b246c4a8a3d763667.zip |
Update AR logger subscriber for Notifications subscriber args change
-rw-r--r-- | activerecord/lib/active_record/notifications.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/notifications.rb b/activerecord/lib/active_record/notifications.rb index a5ce7ac524..562a5b91f4 100644 --- a/activerecord/lib/active_record/notifications.rb +++ b/activerecord/lib/active_record/notifications.rb @@ -1,5 +1,5 @@ require 'active_support/notifications' -ActiveSupport::Notifications.subscribe("sql") do |event| - ActiveRecord::Base.connection.log_info(event.payload[:sql], event.payload[:name], event.duration) +ActiveSupport::Notifications.subscribe("sql") do |name, before, after, result, instrumenter_id, payload| + ActiveRecord::Base.connection.log_info(payload[:sql], name, after - before) end |