From 0822dc01f68eb262274fbedcf97a224e6457ff3b Mon Sep 17 00:00:00 2001 From: Francesco Rodriguez Date: Fri, 11 May 2012 11:41:22 -0500 Subject: improve String#to docs --- activesupport/lib/active_support/core_ext/string/access.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'activesupport') diff --git a/activesupport/lib/active_support/core_ext/string/access.rb b/activesupport/lib/active_support/core_ext/string/access.rb index 5cdf42ce4b..9494a9b69d 100644 --- a/activesupport/lib/active_support/core_ext/string/access.rb +++ b/activesupport/lib/active_support/core_ext/string/access.rb @@ -34,8 +34,8 @@ class String self[position..-1] end - # Returns the beginning of the string up to position. If the position is - # negative, it is counted from the end of the string. + # Returns a substring from the beginning of the string to the given position. + # If the position is negative, it is counted from the end of the string. # # str = "hello" # str.to(0) #=> "h" -- cgit v1.2.3