From e9a23e4f2082a84f93e6dc1134cb6f9fd205ea35 Mon Sep 17 00:00:00 2001 From: Xavier Noria Date: Thu, 17 Dec 2009 00:02:15 +0100 Subject: AS guide: fixes an example --- railties/guides/source/active_support_core_extensions.textile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/railties/guides/source/active_support_core_extensions.textile b/railties/guides/source/active_support_core_extensions.textile index 4b8e2ef691..8ba283122d 100644 --- a/railties/guides/source/active_support_core_extensions.textile +++ b/railties/guides/source/active_support_core_extensions.textile @@ -888,7 +888,7 @@ Similarly, +from+ returns the tail from the element at the passed index on: %w(a b c d).from(2) # => %w(c d) %w(a b c d).from(10) # => nil -[].from(0) # => nil +[].from(0) # => [] The methods +second+, +third+, +fourth+, and +fifth+ return the corresponding element (+first+ is builtin). Thanks to social wisdom and positive constructiveness all around, +forty_two+ is also available. -- cgit v1.2.3