diff options
author | Joshua Peek <josh@joshpeek.com> | 2010-01-18 09:49:05 -0600 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2010-01-18 09:49:38 -0600 |
commit | 68b76a38eb83db8515336ec2e7fd8191798386be (patch) | |
tree | 396db460d1d6a1aefcc68bc48cd6b6c977113309 /activerecord/lib/active_record | |
parent | e27bfad6a5f9e9171148226dee7ce51d41731ea7 (diff) | |
download | rails-68b76a38eb83db8515336ec2e7fd8191798386be.tar.gz rails-68b76a38eb83db8515336ec2e7fd8191798386be.tar.bz2 rails-68b76a38eb83db8515336ec2e7fd8191798386be.zip |
Cleanup deprecation notices.
Diffstat (limited to 'activerecord/lib/active_record')
-rw-r--r-- | activerecord/lib/active_record/named_scope.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/activerecord/lib/active_record/named_scope.rb b/activerecord/lib/active_record/named_scope.rb index 2d88f49f5f..92030e5bfd 100644 --- a/activerecord/lib/active_record/named_scope.rb +++ b/activerecord/lib/active_record/named_scope.rb @@ -9,7 +9,7 @@ module ActiveRecord module ClassMethods # Returns a relation if invoked without any arguments. # - # posts = Post.scoped + # posts = Post.scoped # posts.size # Fires "select count(*) from posts" and returns the count # posts.each {|p| puts p.name } # Fires "select * from posts" and loads post objects # @@ -41,8 +41,8 @@ module ActiveRecord # scope :red, :conditions => {:color => 'red'} # scope :dry_clean_only, :joins => :washing_instructions, :conditions => ['washing_instructions.dry_clean_only = ?', true] # end - # - # The above calls to <tt>scope</tt> define class methods Shirt.red and Shirt.dry_clean_only. Shirt.red, + # + # The above calls to <tt>scope</tt> define class methods Shirt.red and Shirt.dry_clean_only. Shirt.red, # in effect, represents the query <tt>Shirt.find(:all, :conditions => {:color => 'red'})</tt>. # # Unlike <tt>Shirt.find(...)</tt>, however, the object returned by Shirt.red is not an Array; it resembles the association object @@ -120,7 +120,7 @@ module ActiveRecord end def named_scope(*args, &block) - ActiveSupport::Deprecation.warn("Base.named_scope has been deprecated, please use Base.scope instead.", caller) + ActiveSupport::Deprecation.warn("Base.named_scope has been deprecated, please use Base.scope instead", caller) scope(*args, &block) end end |