aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/associations/collection_association.rb
diff options
context:
space:
mode:
authorVijay Dev <vijaydev.cse@gmail.com>2013-05-19 21:40:12 +0530
committerVijay Dev <vijaydev.cse@gmail.com>2013-05-19 21:40:12 +0530
commitd71b0935a956ebedea0bb975525fc0f5672e4088 (patch)
treeea512e13fd13dd144bdbf3469514beb8fba010c6 /activerecord/lib/active_record/associations/collection_association.rb
parentd3d8cfd5689188f48714f49ad000a1c1fbd9edcd (diff)
parent7f24d3d6956a7775771302d143e3b09de681d12f (diff)
downloadrails-d71b0935a956ebedea0bb975525fc0f5672e4088.tar.gz
rails-d71b0935a956ebedea0bb975525fc0f5672e4088.tar.bz2
rails-d71b0935a956ebedea0bb975525fc0f5672e4088.zip
Merge branch 'master' of github.com:lifo/docrails
Diffstat (limited to 'activerecord/lib/active_record/associations/collection_association.rb')
-rw-r--r--activerecord/lib/active_record/associations/collection_association.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/activerecord/lib/active_record/associations/collection_association.rb b/activerecord/lib/active_record/associations/collection_association.rb
index 2a00ac1386..efd7ecb97c 100644
--- a/activerecord/lib/active_record/associations/collection_association.rb
+++ b/activerecord/lib/active_record/associations/collection_association.rb
@@ -237,11 +237,11 @@ module ActiveRecord
end
end
- # Destroy +records+ and remove them from this association calling
- # +before_remove+ and +after_remove+ callbacks.
+ # Deletes the +records+ and removes them from this association calling
+ # +before_remove+ , +after_remove+ , +before_destroy+ and +after_destroy+ callbacks.
#
- # Note that this method will _always_ remove records from the database
- # ignoring the +:dependent+ option.
+ # Note that this method removes records from the database ignoring the
+ # +:dependent+ option.
def destroy(*records)
records = find(records) if records.any? { |record| record.kind_of?(Fixnum) || record.kind_of?(String) }
delete_or_destroy(records, :destroy)