Permalink
Browse files

Delete accepts multiple parameters

  • Loading branch information...
1 parent db2463c commit 3e7224418c7753f8839f6169f08d4b8c41f4b2d4 @binarylogic committed Jun 21, 2009
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/searchlogic/search.rb
@@ -68,8 +68,8 @@ def conditions=(values)
# if a named scope accepts a parameter there is no way to actually delete
# the scope if you do not want it anymore. A nil value might be meaningful
# to that scope.
- def delete(name)
- @conditions.delete(name.to_sym)
+ def delete(*names)
+ names.each { |name| @conditions.delete(name.to_sym) }
self
end

0 comments on commit 3e72244

Please sign in to comment.