aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel/algebra/relations/operations/lock.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/arel/algebra/relations/operations/lock.rb')
-rw-r--r--lib/arel/algebra/relations/operations/lock.rb8
1 files changed, 1 insertions, 7 deletions
diff --git a/lib/arel/algebra/relations/operations/lock.rb b/lib/arel/algebra/relations/operations/lock.rb
index 003bd29c8a..394ad6f0ec 100644
--- a/lib/arel/algebra/relations/operations/lock.rb
+++ b/lib/arel/algebra/relations/operations/lock.rb
@@ -4,13 +4,7 @@ module Arel
def initialize(relation, locked)
super(relation)
- @locked = locked.blank? ? " FOR UPDATE" : locked
- end
-
- def == other
- super || Lock === other &&
- relation == other.relation &&
- locked == other.locked
+ @locked = true == locked ? " FOR UPDATE" : locked
end
end
end