aboutsummaryrefslogtreecommitdiffstats
path: root/guides/source/active_record_querying.md
diff options
context:
space:
mode:
authorMatthew Draper <matthew@trebex.net>2017-05-27 12:46:08 +0930
committerGitHub <noreply@github.com>2017-05-27 12:46:08 +0930
commita824c679f3ef9edca6530241087aafb01965eb26 (patch)
treeb181a165c7272bd47a5770ea82b3267025fa5bfa /guides/source/active_record_querying.md
parent1229e99ca2e9911a20a52ac5b6188e0edaf630bf (diff)
parent7cceb729e64b8eef028dab042b79d8def0730372 (diff)
downloadrails-a824c679f3ef9edca6530241087aafb01965eb26.tar.gz
rails-a824c679f3ef9edca6530241087aafb01965eb26.tar.bz2
rails-a824c679f3ef9edca6530241087aafb01965eb26.zip
Merge pull request #29246 from nihemak/fix-docs-take-first
[ci skip]fix wrong variable name in docs
Diffstat (limited to 'guides/source/active_record_querying.md')
-rw-r--r--guides/source/active_record_querying.md6
1 files changed, 3 insertions, 3 deletions
diff --git a/guides/source/active_record_querying.md b/guides/source/active_record_querying.md
index 07950c6066..aea7515974 100644
--- a/guides/source/active_record_querying.md
+++ b/guides/source/active_record_querying.md
@@ -150,7 +150,7 @@ The `take` method returns `nil` if no record is found and no exception will be r
You can pass in a numerical argument to the `take` method to return up to that number of results. For example
```ruby
-client = Client.take(2)
+clients = Client.take(2)
# => [
# #<Client id: 1, first_name: "Lifo">,
# #<Client id: 220, first_name: "Sara">
@@ -189,7 +189,7 @@ If your [default scope](active_record_querying.html#applying-a-default-scope) co
You can pass in a numerical argument to the `first` method to return up to that number of results. For example
```ruby
-client = Client.first(3)
+clients = Client.first(3)
# => [
# #<Client id: 1, first_name: "Lifo">,
# #<Client id: 2, first_name: "Fifo">,
@@ -240,7 +240,7 @@ If your [default scope](active_record_querying.html#applying-a-default-scope) co
You can pass in a numerical argument to the `last` method to return up to that number of results. For example
```ruby
-client = Client.last(3)
+clients = Client.last(3)
# => [
# #<Client id: 219, first_name: "James">,
# #<Client id: 220, first_name: "Sara">,