Permalink
Browse files

Update AR logger subscriber for Notifications subscriber args change

  • Loading branch information...
1 parent 322b6b2 commit fca32eb6c5b41e4f19a25b7b246c4a8a3d763667 @jeremy jeremy committed Nov 11, 2009
Showing with 2 additions and 2 deletions.
  1. +2 −2 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

1 comment on commit fca32eb

Contributor

rubys commented on fca32eb Nov 11, 2009

This commit causes log entries for sql statements to be in base64 on Ruby 1.8.7.

https://rails.lighthouseapp.com/projects/8994/tickets/3400

Please sign in to comment.