Skip to content

Commit

Permalink
Merge pull request rails#8884 from mattdbridges/array-access-doc-fixes
Browse files Browse the repository at this point in the history
Updating Array access docs more consistent
  • Loading branch information
guilleiguaran committed Jan 10, 2013
2 parents 34126fa + 139461f commit 8c2e4b6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions activesupport/lib/active_support/core_ext/array/access.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,28 +21,28 @@ def to(position)

# Equal to <tt>self[1]</tt>.
#
# %w( a b c d e).second # => "b"
# %w( a b c d e ).second # => "b"
def second
self[1]
end

# Equal to <tt>self[2]</tt>.
#
# %w( a b c d e).third # => "c"
# %w( a b c d e ).third # => "c"
def third
self[2]
end

# Equal to <tt>self[3]</tt>.
#
# %w( a b c d e).fourth # => "d"
# %w( a b c d e ).fourth # => "d"
def fourth
self[3]
end

# Equal to <tt>self[4]</tt>.
#
# %w( a b c d e).fifth # => "e"
# %w( a b c d e ).fifth # => "e"
def fifth
self[4]
end
Expand Down

0 comments on commit 8c2e4b6

Please sign in to comment.