1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

doing sql literal conversion

This commit is contained in:
Aaron Patterson 2010-09-07 11:02:38 -07:00
parent c14c5c16f2
commit 4ef7ee8f35

View file

@ -19,7 +19,11 @@ module Arel
end
def project *projections
@ctx.projections.concat projections
# FIXME: converting these to SQLLiterals is probably not good, but
# rails tests require it.
@ctx.projections.concat projections.map { |x|
String == x.class ? SqlLiteral.new(x) : x
}
self
end