From d36a769234911c8374e09069eb054d4c60eb1b99 Mon Sep 17 00:00:00 2001 From: Sean Griffin Date: Sun, 25 Jan 2015 14:47:47 -0700 Subject: Implement equality for `BindParam` It is impossible to test equality of things constructing trees with bind params otherwise. --- lib/arel/nodes/bind_param.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/arel/nodes') diff --git a/lib/arel/nodes/bind_param.rb b/lib/arel/nodes/bind_param.rb index 160bc21b91..3a4aedc4ba 100644 --- a/lib/arel/nodes/bind_param.rb +++ b/lib/arel/nodes/bind_param.rb @@ -1,6 +1,9 @@ module Arel module Nodes class BindParam < Node + def ==(other) + other.is_a?(BindParam) + end end end end -- cgit v1.2.3