aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorSean Griffin <sean@thoughtbot.com>2014-12-02 15:46:58 -0700
committerSean Griffin <sean@thoughtbot.com>2014-12-02 15:46:58 -0700
commite2f22adfaf4dacd40554db875c35a8a7e1980bd7 (patch)
treea8edee76db67d2c3e82b0827a55bb5089dc6c580 /lib
parent98fc25991137ee09b6800578117f8c1c322680f2 (diff)
downloadrails-e2f22adfaf4dacd40554db875c35a8a7e1980bd7.tar.gz
rails-e2f22adfaf4dacd40554db875c35a8a7e1980bd7.tar.bz2
rails-e2f22adfaf4dacd40554db875c35a8a7e1980bd7.zip
Don't re-quote nodes which are already quoted
We're going to start working on removing type casting from arel. To avoid doing one gigantic commit which moves everything over to eager casting, we need a way to tell Arel that we've already cast it. The easiest path to that is to give it a quoted node, and then we remove this case once we're never returning a Casted node
Diffstat (limited to 'lib')
-rw-r--r--lib/arel/nodes.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/arel/nodes.rb b/lib/arel/nodes.rb
index 2c3c48881b..e62f9f909e 100644
--- a/lib/arel/nodes.rb
+++ b/lib/arel/nodes.rb
@@ -80,7 +80,7 @@ module Arel
def self.build_quoted other, attribute = nil
case other
- when Arel::Nodes::Node, Arel::Attributes::Attribute, Arel::Table, Arel::Nodes::BindParam, Arel::SelectManager
+ when Arel::Nodes::Node, Arel::Attributes::Attribute, Arel::Table, Arel::Nodes::BindParam, Arel::SelectManager, Arel::Nodes::Quoted
other
else
case attribute