From 6d093fb719f4f080d47c8aeadb72201979c604d7 Mon Sep 17 00:00:00 2001 From: Bryan Helmkamp Date: Thu, 1 Oct 2009 00:14:15 -0400 Subject: Removing unused params from #to_sql methods on writes --- lib/arel/engines/sql/relations/writes.rb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'lib/arel/engines') diff --git a/lib/arel/engines/sql/relations/writes.rb b/lib/arel/engines/sql/relations/writes.rb index d648a54d91..42496ef735 100644 --- a/lib/arel/engines/sql/relations/writes.rb +++ b/lib/arel/engines/sql/relations/writes.rb @@ -1,6 +1,6 @@ module Arel class Deletion < Compound - def to_sql(formatter = nil) + def to_sql build_query \ "DELETE", "FROM #{table_sql}", @@ -10,7 +10,7 @@ module Arel end class Insert < Compound - def to_sql(formatter = nil) + def to_sql insertion_attributes_values_sql = if record.is_a?(Value) record.value else @@ -26,7 +26,7 @@ module Arel end class Update < Compound - def to_sql(formatter = nil) + def to_sql build_query \ "UPDATE #{table_sql} SET", assignment_sql, @@ -34,6 +34,7 @@ module Arel end protected + def assignment_sql if assignments.respond_to?(:collect) assignments.collect do |attribute, value| -- cgit v1.2.3