aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/arel/select_manager.rb2
-rw-r--r--lib/arel/table.rb2
-rw-r--r--lib/arel/visitors/to_sql.rb2
3 files changed, 2 insertions, 4 deletions
diff --git a/lib/arel/select_manager.rb b/lib/arel/select_manager.rb
index f1dde6403a..4a652f2c9c 100644
--- a/lib/arel/select_manager.rb
+++ b/lib/arel/select_manager.rb
@@ -106,7 +106,7 @@ module Arel
case relation
when String, Nodes::SqlLiteral
- raise if relation.blank?
+ raise if relation.empty?
klass = Nodes::StringJoin
end
diff --git a/lib/arel/table.rb b/lib/arel/table.rb
index 545e73e3ae..01d4561ff1 100644
--- a/lib/arel/table.rb
+++ b/lib/arel/table.rb
@@ -57,7 +57,7 @@ primary_key (#{caller.first}) is deprecated and will be removed in Arel 4.0.0
case relation
when String, Nodes::SqlLiteral
- raise if relation.blank?
+ raise if relation.empty?
klass = Nodes::StringJoin
end
diff --git a/lib/arel/visitors/to_sql.rb b/lib/arel/visitors/to_sql.rb
index 28c4bd8bfa..a1dee43cab 100644
--- a/lib/arel/visitors/to_sql.rb
+++ b/lib/arel/visitors/to_sql.rb
@@ -103,9 +103,7 @@ module Arel
collector << "UPDATE "
collector = visit o.relation, collector
- values = false
unless o.values.empty?
- values = true
collector << " SET "
collector = inject_join o.values, collector, ", "
end