diff options
author | Zachary Scott <e@zzak.io> | 2015-05-03 11:07:02 -0700 |
---|---|---|
committer | Zachary Scott <e@zzak.io> | 2015-05-03 11:07:02 -0700 |
commit | 8ce44b287f0dab4918a26aeadd0a96a671b1161c (patch) | |
tree | 12a5a26d8285f3c30b2f51cfca6ae24261c4196c /activerecord | |
parent | 71669370ae789f547311821ab880b0f19682b405 (diff) | |
parent | e61c32cb38dc3853a66ecb87550ba97be634c442 (diff) | |
download | rails-8ce44b287f0dab4918a26aeadd0a96a671b1161c.tar.gz rails-8ce44b287f0dab4918a26aeadd0a96a671b1161c.tar.bz2 rails-8ce44b287f0dab4918a26aeadd0a96a671b1161c.zip |
Merge pull request #19988 from kamipo/move_comment_about_microseconds
Move comment about microseconds [ci skip]
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/quoting.rb | 2 | ||||
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/postgresql/quoting.rb | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb b/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb index 91c7298983..2c7409b2dc 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb @@ -123,6 +123,8 @@ module ActiveRecord 'f' end + # Quote date/time values for use in SQL input. Includes microseconds + # if the value is a Time responding to usec. def quoted_date(value) if value.acts_like?(:time) zone_conversion_method = ActiveRecord::Base.default_timezone == :utc ? :getutc : :getlocal diff --git a/activerecord/lib/active_record/connection_adapters/postgresql/quoting.rb b/activerecord/lib/active_record/connection_adapters/postgresql/quoting.rb index b7755c4593..f175730551 100644 --- a/activerecord/lib/active_record/connection_adapters/postgresql/quoting.rb +++ b/activerecord/lib/active_record/connection_adapters/postgresql/quoting.rb @@ -40,8 +40,7 @@ module ActiveRecord PGconn.quote_ident(name.to_s) end - # Quote date/time values for use in SQL input. Includes microseconds - # if the value is a Time responding to usec. + # Quote date/time values for use in SQL input. def quoted_date(value) #:nodoc: if value.year <= 0 bce_year = format("%04d", -value.year + 1) |