diff options
author | Sean Griffin <sean@thoughtbot.com> | 2014-12-05 15:32:58 -0700 |
---|---|---|
committer | Sean Griffin <sean@thoughtbot.com> | 2014-12-05 15:34:30 -0700 |
commit | 670e7941d5482f7124420965d4fbd7bea45a3155 (patch) | |
tree | efcd8f1da3b25692ecb0f7af55fbce99578b8946 /activerecord/test/cases/types_test.rb | |
parent | a78736bd48408976459b7ff4279d5e6f356a970f (diff) | |
download | rails-670e7941d5482f7124420965d4fbd7bea45a3155.tar.gz rails-670e7941d5482f7124420965d4fbd7bea45a3155.tar.bz2 rails-670e7941d5482f7124420965d4fbd7bea45a3155.zip |
Correctly respect subtypes for PG arrays and ranges
The type registration was simply looking for the OID, and eagerly
fetching/constructing the sub type when it was registered. However,
numeric types have additional parameters which are extracted from the
actual SQL string of the type during lookup, and can have their behavior
change based on the result.
We simply need to use the block form of registration, and look up the
subtype lazily instead.
Fixes #17935
Diffstat (limited to 'activerecord/test/cases/types_test.rb')
0 files changed, 0 insertions, 0 deletions