Skip to content
Browse files

Restore .to_s to escape_hstore

  • Loading branch information...
1 parent 0c46dbb commit 1a05e15e13e8c4dbe67cf15d83d536f1cf6fbecf @rf- rf- committed Apr 24, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
View
2 activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
@@ -89,7 +89,7 @@ def string_to_hstore(string)
def escape_hstore(value)
value.nil? ? 'NULL'
: value == "" ? '""'
- : '"%s"' % value.gsub(/(["\\])/, '\\\\\1')
+ : '"%s"' % value.to_s.gsub(/(["\\])/, '\\\\\1')
end
end
# :startdoc:

0 comments on commit 1a05e15

Please sign in to comment.
Something went wrong with that request. Please try again.