diff options
Diffstat (limited to 'activerecord/lib/active_record/associations/association_proxy.rb')
-rw-r--r-- | activerecord/lib/active_record/associations/association_proxy.rb | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/activerecord/lib/active_record/associations/association_proxy.rb b/activerecord/lib/active_record/associations/association_proxy.rb index 2f9ba31786..9fc0d44a01 100644 --- a/activerecord/lib/active_record/associations/association_proxy.rb +++ b/activerecord/lib/active_record/associations/association_proxy.rb @@ -77,12 +77,6 @@ module ActiveRecord @target.inspect end - def to_xml(options={}, &block) - if load_target - @target.to_xml(options, &block) - end - end - protected def dependent? @reflection.options[:dependent] @@ -126,9 +120,9 @@ module ActiveRecord end private - def method_missing(method, *args) + def method_missing(method, *args, &block) if load_target - @target.send(method, *args) { |*block_args| yield(*block_args) if block_given? } + @target.send(method, *args, &block) end end |