aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters/postgresql/cast.rb
diff options
context:
space:
mode:
authorGodfrey Chan <godfreykfc@gmail.com>2014-06-29 14:49:24 -0700
committerGodfrey Chan <godfreykfc@gmail.com>2014-06-29 14:49:24 -0700
commit7a52d6bba0f3db1d1f145e80d161446668393410 (patch)
treec369850dc181114f8961fae5fbdddcf425d3f484 /activerecord/lib/active_record/connection_adapters/postgresql/cast.rb
parent374958b6debd03f5ce4dc0bd2071f3bc9baef330 (diff)
parent314d5579ab63ed9606d25a59cb4010be85fb3b17 (diff)
downloadrails-7a52d6bba0f3db1d1f145e80d161446668393410.tar.gz
rails-7a52d6bba0f3db1d1f145e80d161446668393410.tar.bz2
rails-7a52d6bba0f3db1d1f145e80d161446668393410.zip
Merge pull request #15983 from sgrif/sg-inline-point
Use the type object when sending point columns to the DB
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters/postgresql/cast.rb')
-rw-r--r--activerecord/lib/active_record/connection_adapters/postgresql/cast.rb8
1 files changed, 0 insertions, 8 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/postgresql/cast.rb b/activerecord/lib/active_record/connection_adapters/postgresql/cast.rb
index b0a161ff32..95fc461bae 100644
--- a/activerecord/lib/active_record/connection_adapters/postgresql/cast.rb
+++ b/activerecord/lib/active_record/connection_adapters/postgresql/cast.rb
@@ -2,14 +2,6 @@ module ActiveRecord
module ConnectionAdapters
module PostgreSQL
module Cast # :nodoc:
- def point_to_string(point) # :nodoc:
- "(#{number_for_point(point[0])},#{number_for_point(point[1])})"
- end
-
- def number_for_point(number)
- number.to_s.gsub(/\.0$/, '')
- end
-
def hstore_to_string(object, array_member = false) # :nodoc:
if Hash === object
string = object.map { |k, v| "#{escape_hstore(k)}=>#{escape_hstore(v)}" }.join(', ')