From a00bca625f70ee99d3fdfe65b5bf08d932d168a2 Mon Sep 17 00:00:00 2001 From: Vasiliy Ermolovich Date: Thu, 17 May 2012 23:01:35 +0300 Subject: update AS docs --- guides/source/active_support_core_extensions.textile | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'guides') diff --git a/guides/source/active_support_core_extensions.textile b/guides/source/active_support_core_extensions.textile index 6443255f5d..80faffa49c 100644 --- a/guides/source/active_support_core_extensions.textile +++ b/guides/source/active_support_core_extensions.textile @@ -84,7 +84,7 @@ The following values are considered to be blank in a Rails application: * any other object that responds to +empty?+ and it is empty. -INFO: In Ruby 1.9 the predicate for strings uses the Unicode-aware character class [:space:], so for example U+2029 (paragraph separator) is considered to be whitespace. In Ruby 1.8 whitespace is considered to be \s together with the ideographic space U+3000. +INFO: The predicate for strings uses the Unicode-aware character class [:space:], so for example U+2029 (paragraph separator) is considered to be whitespace. WARNING: Note that numbers are not mentioned, in particular 0 and 0.0 are *not* blank. @@ -2093,7 +2093,7 @@ h5. +to_formatted_s+ The method +to_formatted_s+ acts like +to_s+ by default. -If the array contains items that respond to +id+, however, it may be passed the symbol :db as argument. That's typically used with collections of ARs, though technically any object in Ruby 1.8 responds to +id+ indeed. Returned strings are: +If the array contains items that respond to +id+, however, it may be passed the symbol :db as argument. That's typically used with collections of ARs. Returned strings are: [].to_formatted_s(:db) # => "null" @@ -2869,8 +2869,6 @@ d.prev_year # => Sun, 28 Feb 1999 d.next_year # => Wed, 28 Feb 2001 -Active Support defines these methods as well for Ruby 1.8. - +prev_year+ is aliased to +last_year+. h6. +prev_month+, +next_month+ @@ -2892,8 +2890,6 @@ Date.new(2000, 5, 31).next_month # => Fri, 30 Jun 2000 Date.new(2000, 1, 31).next_month # => Tue, 29 Feb 2000 -Active Support defines these methods as well for Ruby 1.8. - +prev_month+ is aliased to +last_month+. h6. +beginning_of_week+, +end_of_week+ -- cgit v1.2.3