From 8242345c43ca89e2430a0278ce863b2733ae6261 Mon Sep 17 00:00:00 2001 From: Carlos Antonio da Silva Date: Mon, 7 Jan 2013 21:22:43 -0200 Subject: Fix named scope + class method example Closes #8804 [ci skip] --- activerecord/lib/active_record/scoping/named.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/activerecord/lib/active_record/scoping/named.rb b/activerecord/lib/active_record/scoping/named.rb index 8b7eda6eee..01fbb96b8e 100644 --- a/activerecord/lib/active_record/scoping/named.rb +++ b/activerecord/lib/active_record/scoping/named.rb @@ -134,16 +134,14 @@ module ActiveRecord # end # # def self.titles - # map(&:title) + # pluck(:title) # end - # # end # # We are able to call the methods like this: # # Article.published.featured.latest_article # Article.featured.titles - def scope(name, body, &block) extension = Module.new(&block) if block -- cgit v1.2.3