From becdb49186c575bf96a82a949ac04b6078680d52 Mon Sep 17 00:00:00 2001 From: Geoff Buesing Date: Sat, 24 Nov 2007 04:59:21 +0000 Subject: Honor Ruby's default calendar reform setting when creating DateTime objects via ActiveRecord's Time -> DateTime overflow, Time#time_with_datetime_fallback, Time#to_datetime, Date#to_datetime and String#to_datetime. Closes #10201 git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8199 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- activesupport/lib/active_support/core_ext/date/conversions.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activesupport/lib/active_support/core_ext/date/conversions.rb') diff --git a/activesupport/lib/active_support/core_ext/date/conversions.rb b/activesupport/lib/active_support/core_ext/date/conversions.rb index 511c69544e..e0fadbd72f 100644 --- a/activesupport/lib/active_support/core_ext/date/conversions.rb +++ b/activesupport/lib/active_support/core_ext/date/conversions.rb @@ -53,7 +53,7 @@ module ActiveSupport #:nodoc: # Converts self to a Ruby DateTime object; time is set to beginning of day def to_datetime - ::DateTime.civil(year, month, day, 0, 0, 0, 0, 0) + ::DateTime.civil(year, month, day, 0, 0, 0, 0) end if RUBY_VERSION < '1.9' def xmlschema -- cgit v1.2.3