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

No need to send public methods

This commit is contained in:
Akira Matsuda 2013-02-26 16:59:12 +09:00
parent 92aa789ce1
commit 39394ab3db
3 changed files with 3 additions and 3 deletions

View file

@ -146,7 +146,7 @@ module ActiveRecord
def interpolate(sql, record = nil)
if sql.respond_to?(:to_proc)
owner.send(:instance_exec, record, &sql)
owner.instance_exec(record, &sql)
else
sql
end

View file

@ -70,7 +70,7 @@ module ActiveRecord
end
def instantiate(row)
@cached_record[record_id(row)] ||= active_record.send(:instantiate, extract_record(row))
@cached_record[record_id(row)] ||= active_record.instantiate(extract_record(row))
end
end
end

View file

@ -347,7 +347,7 @@ module ActiveRecord
end
# reconstruct the scope now that we know the owner's id
association.send(:reset_scope) if association.respond_to?(:reset_scope)
association.reset_scope if association.respond_to?(:reset_scope)
end
end