Browse files

Fix bug with empty params[:keywords]

  • Loading branch information...
1 parent 2d2fc61 commit 8fc8edd713593da5661c115aafe06a0cb876ba21 @romul committed Sep 21, 2009
Showing with 1 addition and 1 deletion.
  1. +1 −1 search_extension.rb
View
2 search_extension.rb
@@ -30,7 +30,7 @@ def collection
@search = @search.taxons_id_equals_any(@taxon.descendents.inject([@taxon.id]) { |clause, t| clause << t.id } )
end
- if (params[:keywords])
+ unless params[:keywords].blank?
query = params[:keywords].to_s.split
@search = @search.name_or_description_like_any(query)
end

0 comments on commit 8fc8edd

Please sign in to comment.