diff options
author | Benjamin Floering <floering@ieee.org> | 2009-05-17 23:35:47 -0700 |
---|---|---|
committer | Pratik Naik <pratiknaik@gmail.com> | 2009-05-18 13:56:17 +0200 |
commit | 27de7f150b57a18d4ccdd274f6f8b621b58108c6 (patch) | |
tree | 266fe0c48b0920757c3e65fa44413c5426a85b7b /activerecord/lib | |
parent | 49afe81a13a98d1878f2400bef11a7b89468dff0 (diff) | |
download | rails-27de7f150b57a18d4ccdd274f6f8b621b58108c6.tar.gz rails-27de7f150b57a18d4ccdd274f6f8b621b58108c6.tar.bz2 rails-27de7f150b57a18d4ccdd274f6f8b621b58108c6.zip |
Fixed limited eager loading associations with numbers in the name [#2668 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
Diffstat (limited to 'activerecord/lib')
-rwxr-xr-x | activerecord/lib/active_record/associations.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations.rb b/activerecord/lib/active_record/associations.rb index c5e4df4950..76726b7845 100755 --- a/activerecord/lib/active_record/associations.rb +++ b/activerecord/lib/active_record/associations.rb @@ -1668,7 +1668,7 @@ module ActiveRecord def tables_in_string(string) return [] if string.blank? - string.scan(/([\.a-zA-Z_]+).?\./).flatten + string.scan(/([a-zA-Z_][\.\w]+).?\./).flatten end def tables_in_hash(hash) |