aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
authorKonstantinos Rousis <rousisk@gmail.com>2015-02-18 09:44:43 +0100
committerKonstantinos Rousis <rousisk@gmail.com>2015-02-18 09:44:43 +0100
commit6ef2ce0aedd8a61744a8b533e727b78d59184177 (patch)
treed4428c33bba849769d6e72b78808b3e2ba48705d /activerecord
parent07b659ca3f6945b5032690f38fdd0e080b842d37 (diff)
downloadrails-6ef2ce0aedd8a61744a8b533e727b78d59184177.tar.gz
rails-6ef2ce0aedd8a61744a8b533e727b78d59184177.tar.bz2
rails-6ef2ce0aedd8a61744a8b533e727b78d59184177.zip
Replace deprecated readonly option with scope blocks in docs and guide
Diffstat (limited to 'activerecord')
-rw-r--r--activerecord/lib/active_record/associations.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/associations.rb b/activerecord/lib/active_record/associations.rb
index 260ef71e64..a146d78a5a 100644
--- a/activerecord/lib/active_record/associations.rb
+++ b/activerecord/lib/active_record/associations.rb
@@ -1386,7 +1386,7 @@ module ActiveRecord
# has_one :last_comment, -> { order 'posted_on' }, class_name: "Comment"
# has_one :project_manager, -> { where role: 'project_manager' }, class_name: "Person"
# has_one :attachment, as: :attachable
- # has_one :boss, readonly: :true
+ # has_one :boss, -> { readonly }
# has_one :club, through: :membership
# has_one :primary_address, -> { where primary: true }, through: :addressables, source: :addressable
# has_one :credit_card, required: true
@@ -1514,7 +1514,7 @@ module ActiveRecord
# belongs_to :valid_coupon, ->(o) { where "discounts > ?", o.payments_count },
# class_name: "Coupon", foreign_key: "coupon_id"
# belongs_to :attachable, polymorphic: true
- # belongs_to :project, readonly: true
+ # belongs_to :project, -> { readonly }
# belongs_to :post, counter_cache: true
# belongs_to :comment, touch: true
# belongs_to :company, touch: :employees_last_updated_at