From 1f5ed8eb20231644525bdad9a94a91e810191186 Mon Sep 17 00:00:00 2001 From: Ernie Miller Date: Fri, 29 Apr 2011 14:27:45 -0400 Subject: Stop calling to_s on aliases, require them to be strings already. --- lib/arel/nodes/function.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/arel/nodes') diff --git a/lib/arel/nodes/function.rb b/lib/arel/nodes/function.rb index 3263ff9cd4..85347fc028 100644 --- a/lib/arel/nodes/function.rb +++ b/lib/arel/nodes/function.rb @@ -6,12 +6,12 @@ module Arel def initialize expr, aliaz = nil @expressions = expr - @alias = aliaz && SqlLiteral.new(aliaz.to_s) + @alias = aliaz && SqlLiteral.new(aliaz) @distinct = false end def as aliaz - self.alias = SqlLiteral.new(aliaz.to_s) + self.alias = SqlLiteral.new(aliaz) self end end -- cgit v1.2.3