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

Merge pull request #17434 from claudiob/remove-redundant-to-s

Remove redundant `to_s` in interpolation
This commit is contained in:
Xavier Noria 2014-10-30 08:16:25 +01:00
commit 7cf4d5465d

View file

@ -836,9 +836,9 @@ module ActiveRecord
# Gather up all of the SET variables...
variable_assignments = variables.map do |k, v|
if v == ':default' || v == :default
"@@SESSION.#{k.to_s} = DEFAULT" # Sets the value to the global or compile default
"@@SESSION.#{k} = DEFAULT" # Sets the value to the global or compile default
elsif !v.nil?
"@@SESSION.#{k.to_s} = #{quote(v)}"
"@@SESSION.#{k} = #{quote(v)}"
end
# or else nil; compact to clear nils out
end.compact.join(', ')