aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record
diff options
context:
space:
mode:
authorVijay Dev <vijaydev.cse@gmail.com>2012-05-04 04:57:07 -0700
committerVijay Dev <vijaydev.cse@gmail.com>2012-05-04 04:57:07 -0700
commitb24f1ce13884a86d6d93d0b16e1fc3716360b65a (patch)
tree5f9bd4d19c18d287fa853e7f5508fd3c5e675404 /activerecord/lib/active_record
parentd1729b917f13810a01ec99b9795a4cce8ee9361d (diff)
parent0f2555f0af279c925280e051db3a3c29359c3d2a (diff)
downloadrails-b24f1ce13884a86d6d93d0b16e1fc3716360b65a.tar.gz
rails-b24f1ce13884a86d6d93d0b16e1fc3716360b65a.tar.bz2
rails-b24f1ce13884a86d6d93d0b16e1fc3716360b65a.zip
Merge pull request #5650 from sekrett/master
Documentation fix: Change the example for habtm association to use proc according to changelog
Diffstat (limited to 'activerecord/lib/active_record')
-rw-r--r--activerecord/lib/active_record/associations.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations.rb b/activerecord/lib/active_record/associations.rb
index b901f06ca4..95bb742c50 100644
--- a/activerecord/lib/active_record/associations.rb
+++ b/activerecord/lib/active_record/associations.rb
@@ -1596,7 +1596,7 @@ module ActiveRecord
# has_and_belongs_to_many :categories, :join_table => "prods_cats"
# has_and_belongs_to_many :categories, :readonly => true
# has_and_belongs_to_many :active_projects, :join_table => 'developers_projects', :delete_sql =>
- # "DELETE FROM developers_projects WHERE active=1 AND developer_id = #{id} AND project_id = #{record.id}"
+ # proc { |record| "DELETE FROM developers_projects WHERE active=1 AND developer_id = #{id} AND project_id = #{record.id}" }
def has_and_belongs_to_many(name, options = {}, &extension)
Builder::HasAndBelongsToMany.build(self, name, options, &extension)
end