aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
diff options
context:
space:
mode:
authorJosé Valim <jose.valim@gmail.com>2011-11-28 11:18:39 +0100
committerJosé Valim <jose.valim@gmail.com>2011-11-28 11:18:39 +0100
commit89925e817c356c292a195c894779b55307c41512 (patch)
tree3deb815ab032ba3788595b60d66208ebe57fbdad /activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
parent152bd3c510a735dfb493017ecb487e931e9791a8 (diff)
downloadrails-89925e817c356c292a195c894779b55307c41512.tar.gz
rails-89925e817c356c292a195c894779b55307c41512.tar.bz2
rails-89925e817c356c292a195c894779b55307c41512.zip
Revert "Use any instead of length"
This reverts commit 1756629835d39f60ef4c96aff81ac503c71b98b7.
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb')
-rw-r--r--activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
index 852debcdde..2f01fbb829 100644
--- a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
+++ b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
@@ -1239,7 +1239,7 @@ module ActiveRecord
if match_data
rest = name[match_data[0].length, name.length]
rest = rest[1, rest.length] if rest.start_with? "."
- [match_data[1], (rest.any? ? rest : nil)]
+ [match_data[1], (rest.length > 0 ? rest : nil)]
end
end