diff options
author | Yves Senn <yves.senn@gmail.com> | 2014-04-24 12:39:02 -0500 |
---|---|---|
committer | Yves Senn <yves.senn@gmail.com> | 2014-04-24 12:39:02 -0500 |
commit | 10ed70185a664b34c1177c24b7ab06cd74502183 (patch) | |
tree | 810adee9f2e50b2a8c61bd282779bbfd1fd17a13 /activerecord/lib | |
parent | a5db212a300fee63994d4f6538fb5eb3bfab0490 (diff) | |
parent | d080e8c201b7200f7f851c7d837cd658968c5255 (diff) | |
download | rails-10ed70185a664b34c1177c24b7ab06cd74502183.tar.gz rails-10ed70185a664b34c1177c24b7ab06cd74502183.tar.bz2 rails-10ed70185a664b34c1177c24b7ab06cd74502183.zip |
Merge pull request #14859 from jefflai2/datetime_type
PostgreSQL Timestamps always map to `:datetime`.
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/postgresql/oid.rb | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/postgresql/oid.rb b/activerecord/lib/active_record/connection_adapters/postgresql/oid.rb index 9e898015a6..540b3694b5 100644 --- a/activerecord/lib/active_record/connection_adapters/postgresql/oid.rb +++ b/activerecord/lib/active_record/connection_adapters/postgresql/oid.rb @@ -209,12 +209,7 @@ This is not reliable and will be removed in the future. class Timestamp < Type def type; :timestamp; end def simplified_type(sql_type) - case sql_type - when /^timestamp with(?:out)? time zone$/ - :datetime - else - :timestamp - end + :datetime end def type_cast(value) |