Skip to content

Commit

Permalink
Formally deprecate the deprecated finders. [Koz]
Browse files Browse the repository at this point in the history
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4682 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information
NZKoz committed Aug 5, 2006
1 parent 52d4166 commit a7f1586
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions activerecord/CHANGELOG
@@ -1,5 +1,7 @@
*SVN*

* Formally deprecate the deprecated finders. [Koz]

* Formally deprecate rich associations. [Koz]

* Fixed that default timezones for new / initialize should uphold utc setting #5709 [daniluk@yahoo.com]
Expand Down
3 changes: 3 additions & 0 deletions activerecord/lib/active_record/deprecated_finders.rb
Expand Up @@ -10,6 +10,7 @@ class << self
def find_on_conditions(ids, conditions) # :nodoc:
find(ids, :conditions => conditions)
end
deprecate :find_on_conditions

# This method is deprecated in favor of find(:first, options).
#
Expand All @@ -21,6 +22,7 @@ def find_on_conditions(ids, conditions) # :nodoc:
def find_first(conditions = nil, orderings = nil, joins = nil) # :nodoc:
find(:first, :conditions => conditions, :order => orderings, :joins => joins)
end
deprecate :find_first

# This method is deprecated in favor of find(:all, options).
#
Expand All @@ -36,6 +38,7 @@ def find_all(conditions = nil, orderings = nil, limit = nil, joins = nil) # :nod
limit, offset = limit.is_a?(Array) ? limit : [ limit, nil ]
find(:all, :conditions => conditions, :order => orderings, :joins => joins, :limit => limit, :offset => offset)
end
deprecate :find_all
end
end
end

0 comments on commit a7f1586

Please sign in to comment.