diff options
author | Pratik Naik <pratiknaik@gmail.com> | 2010-01-12 21:43:55 +0530 |
---|---|---|
committer | Pratik Naik <pratiknaik@gmail.com> | 2010-01-12 21:43:55 +0530 |
commit | 182c5a0e1f6a2268557ca43ed953d23b32e0483f (patch) | |
tree | 4a753bb5819b461b3a7617f9e676de15e9226933 | |
parent | 7286f0f4c8117e2210834070d30378ffb12dba23 (diff) | |
download | rails-182c5a0e1f6a2268557ca43ed953d23b32e0483f.tar.gz rails-182c5a0e1f6a2268557ca43ed953d23b32e0483f.tar.bz2 rails-182c5a0e1f6a2268557ca43ed953d23b32e0483f.zip |
Table alias should be considered when checking for equality
-rw-r--r-- | lib/arel/engines/sql/relations/table.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/arel/engines/sql/relations/table.rb b/lib/arel/engines/sql/relations/table.rb index 0634436280..a409d8223f 100644 --- a/lib/arel/engines/sql/relations/table.rb +++ b/lib/arel/engines/sql/relations/table.rb @@ -52,8 +52,9 @@ module Arel end def ==(other) - Table === other and - name == other.name + Table === other and + name == other.name and + table_alias == other.table_alias end end end |