From 7e76740d2a5ee14b308c7e40f9c95354d19f6189 Mon Sep 17 00:00:00 2001 From: Rick Olson Date: Tue, 11 Apr 2006 01:10:42 +0000 Subject: Allow multiple association extensions with :extend option (closes #4666) [Josh Susser] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4206 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- activerecord/lib/active_record/associations/association_proxy.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/lib/active_record/associations/association_proxy.rb') diff --git a/activerecord/lib/active_record/associations/association_proxy.rb b/activerecord/lib/active_record/associations/association_proxy.rb index 403c036db5..adf7ad6ac6 100644 --- a/activerecord/lib/active_record/associations/association_proxy.rb +++ b/activerecord/lib/active_record/associations/association_proxy.rb @@ -8,7 +8,7 @@ module ActiveRecord def initialize(owner, reflection) @owner, @reflection = owner, reflection - proxy_extend(reflection.options[:extend]) if reflection.options[:extend] + Array(reflection.options[:extend]).each { |ext| proxy_extend(ext) } reset end -- cgit v1.2.3