Open freibuis opened 9 years ago
I rolled back this commit and a problems disappeared. commit 423e786f17701bc64d8b13dd2ae664bb2487837c
I am not sure wihat this commit is trying to achieve
in => (args[1].nil?) ? '' : ( args[1][:in] || '' )
wouldnt it be better just to have
in: ''
I can confirm that this problem exists in 1.6.1 and reverting to 1.6.0 fixes the issue.
this is still present in v1.6.1
The sad thing is that this breaks the basic example from the docs (because find(:all) without providing any filter raises the exception), thereby greatly diminishing the usefulness of the active_directory gem.
Comment out line 269 in ~/.rvm/gems/ruby-2.4.1/gems/active_directory-1.6.1.1/lib/active_directory/base.rb
267 :in => (args[1].nil?) ? '' : ( args[1][:in] || '' ) 268 } 269 #options[:filter].delete(:in) 270 271 cached_results = find_cached_results(args[1]) 272 return cached_results if cached_results or cached_results.nil?
This line
(https://github.com/Mazwak/active_directory/blob/master/lib/active_directory/base.rb#L269)
causes
undefined method 'delete' for Net::LDAP::Filter
if I delete this.. it seems to work (not sure what it was trying to do in the first place)I cant find any method called delete on Net::LDAP::Filter
This is issue was introduced from 1.6.0 -> 1.6.1