mirror of https://github.com/rails/rails
docs, get rid of artifact in `RecordFetchWarning` docs.
[ci skip] There was a `ActiveRecord::Relation::RecordFetchWarning::ActiveSupport` artifact caused by subscribing to AS notifications.
This commit is contained in:
parent
b4250b5c92
commit
cfd5b0007b
|
@ -23,11 +23,13 @@ module ActiveRecord
|
|||
end
|
||||
end
|
||||
|
||||
# :stopdoc:
|
||||
ActiveSupport::Notifications.subscribe("sql.active_record") do |*args|
|
||||
payload = args.last
|
||||
|
||||
QueryRegistry.queries << payload[:sql]
|
||||
end
|
||||
# :startdoc:
|
||||
|
||||
class QueryRegistry # :nodoc:
|
||||
extend ActiveSupport::PerThreadRegistry
|
||||
|
|
Loading…
Reference in New Issue