diff options
author | Marcel Molina <marcel@vernix.org> | 2006-03-30 22:27:32 +0000 |
---|---|---|
committer | Marcel Molina <marcel@vernix.org> | 2006-03-30 22:27:32 +0000 |
commit | 3f049b0b6b5a338786c3dfafb31edf937f4ecb13 (patch) | |
tree | 8a50caa833b407feca119b5d2de61ba9e46ce299 /activerecord/lib/active_record/base.rb | |
parent | 58dd49a7ae13471b8f8e359286307853bfc22529 (diff) | |
download | rails-3f049b0b6b5a338786c3dfafb31edf937f4ecb13.tar.gz rails-3f049b0b6b5a338786c3dfafb31edf937f4ecb13.tar.bz2 rails-3f049b0b6b5a338786c3dfafb31edf937f4ecb13.zip |
Do not implicitly mark recordss of has_many :through as readonly but do mark habtm records as readonly (eventually only on join tables without rich attributes).
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4107 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/lib/active_record/base.rb')
-rwxr-xr-x | activerecord/lib/active_record/base.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/base.rb b/activerecord/lib/active_record/base.rb index f6bee7b6ae..8078b4113b 100755 --- a/activerecord/lib/active_record/base.rb +++ b/activerecord/lib/active_record/base.rb @@ -1325,7 +1325,7 @@ module ActiveRecord #:nodoc: unless options.has_key?(:readonly) if scoped?(:find, :readonly) options[:readonly] = scope(:find, :readonly) - elsif !options[:joins].blank? + elsif !options[:joins].blank? && !options[:select] options[:readonly] = true end end @@ -2064,4 +2064,4 @@ module ActiveRecord #:nodoc: value end end -end
\ No newline at end of file +end |