Merge pull request #3232 from lukaselmer/patch-1

Update documentation of fetch
This commit is contained in:
Yukihiro "Matz" Matsumoto
2016-11-03 13:39:24 +09:00
committed by GitHub
+3 -2
View File
@@ -275,8 +275,9 @@ class Array
# +default+ value.
#
# Alternatively, if a block is given it will only be executed when an
# invalid +index+ is referenced. Negative values of +index+ count from the
# end of the array.
# invalid +index+ is referenced.
#
# Negative values of +index+ count from the end of the array.
#
# a = [ 11, 22, 33, 44 ]
# a.fetch(1) #=> 22