From 271c685a6716e50b7badcdf29aaf208d3c61da5d Mon Sep 17 00:00:00 2001 From: blackhedd Date: Thu, 4 May 2006 12:06:34 +0000 Subject: [PATCH] Enabled the left side of a filter-specification to be a Symbol. Previously it had to be a String. --- lib/net/ldap/filter.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/net/ldap/filter.rb b/lib/net/ldap/filter.rb index 66848a4..84e8c7b 100644 --- a/lib/net/ldap/filter.rb +++ b/lib/net/ldap/filter.rb @@ -180,7 +180,7 @@ class Filter case @op when :eq if @right == "*" # present - @left.to_ber_contextspecific 7 + @left.to_s.to_ber_contextspecific 7 elsif @right =~ /[\*]/ #substring ary = @right.split( /[\*]+/ ) final_star = @right =~ /[\*]$/ @@ -198,9 +198,9 @@ class Filter unless final_star seq << ary.shift.to_ber_contextspecific(2) end - [@left.to_ber, seq.to_ber].to_ber_contextspecific 4 + [@left.to_s.to_ber, seq.to_ber].to_ber_contextspecific 4 else #equality - [@left.to_ber, @right.to_ber].to_ber_contextspecific 3 + [@left.to_s.to_ber, @right.to_ber].to_ber_contextspecific 3 end when :and ary = [@left.coalesce(:and), @right.coalesce(:and)].flatten