mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Update some references to finder options [ci skip]
Passing conditions to `find` was deprecated in Rails 4.0.
This commit is contained in:
parent
c70112e74f
commit
c5ee0ba6e2
2 changed files with 5 additions and 5 deletions
|
@ -173,9 +173,9 @@ module ActiveRecord
|
||||||
class RangeError < StatementInvalid
|
class RangeError < StatementInvalid
|
||||||
end
|
end
|
||||||
|
|
||||||
# Raised when number of bind variables in statement given to +:condition+ key
|
# Raised when the number of placeholders in an SQL fragment passed to
|
||||||
# (for example, when using {ActiveRecord::Base.find}[rdoc-ref:FinderMethods#find] method)
|
# {ActiveRecord::Base.where}[rdoc-ref:QueryMethods#where]
|
||||||
# does not match number of expected values supplied.
|
# does not match the number of values supplied.
|
||||||
#
|
#
|
||||||
# For example, when there are two placeholders with only one value supplied:
|
# For example, when there are two placeholders with only one value supplied:
|
||||||
#
|
#
|
||||||
|
|
|
@ -284,9 +284,9 @@ module ActiveRecord
|
||||||
# * Integer - Finds the record with this primary key.
|
# * Integer - Finds the record with this primary key.
|
||||||
# * String - Finds the record with a primary key corresponding to this
|
# * String - Finds the record with a primary key corresponding to this
|
||||||
# string (such as <tt>'5'</tt>).
|
# string (such as <tt>'5'</tt>).
|
||||||
# * Array - Finds the record that matches these +find+-style conditions
|
# * Array - Finds the record that matches these +where+-style conditions
|
||||||
# (such as <tt>['name LIKE ?', "%#{query}%"]</tt>).
|
# (such as <tt>['name LIKE ?', "%#{query}%"]</tt>).
|
||||||
# * Hash - Finds the record that matches these +find+-style conditions
|
# * Hash - Finds the record that matches these +where+-style conditions
|
||||||
# (such as <tt>{name: 'David'}</tt>).
|
# (such as <tt>{name: 'David'}</tt>).
|
||||||
# * +false+ - Returns always +false+.
|
# * +false+ - Returns always +false+.
|
||||||
# * No args - Returns +false+ if the relation is empty, +true+ otherwise.
|
# * No args - Returns +false+ if the relation is empty, +true+ otherwise.
|
||||||
|
|
Loading…
Reference in a new issue