diff options
author | Daniel Luz <dev@mernen.com> | 2008-12-01 02:58:39 -0200 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2008-12-16 14:34:02 +0100 |
commit | c4023cbe206415cf3ca1ca92cd9980a4aa4aed00 (patch) | |
tree | 21ad99adbfb78ad36c93cc693c5e1028a6ac15fa | |
parent | 46c7dd234807b2d24c8c742acb18c633b69e385d (diff) | |
download | rails-c4023cbe206415cf3ca1ca92cd9980a4aa4aed00.tar.gz rails-c4023cbe206415cf3ca1ca92cd9980a4aa4aed00.tar.bz2 rails-c4023cbe206415cf3ca1ca92cd9980a4aa4aed00.zip |
Update documentation for default_scope
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
-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 a23518b357..87c0002463 100755 --- a/activerecord/lib/active_record/base.rb +++ b/activerecord/lib/active_record/base.rb @@ -2052,10 +2052,10 @@ module ActiveRecord #:nodoc: end # Sets the default options for the model. The format of the - # <tt>method_scoping</tt> argument is the same as in with_scope. + # <tt>options</tt> argument is the same as in find. # # class Person < ActiveRecord::Base - # default_scope :find => { :order => 'last_name, first_name' } + # default_scope :order => 'last_name, first_name' # end def default_scope(options = {}) self.default_scoping << { :find => options, :create => (options.is_a?(Hash) && options.has_key?(:conditions)) ? options[:conditions] : {} } |