Permalink
Browse files

Add update_keywords

  • Loading branch information...
1 parent c1d1959 commit f5ffec5c0ef9ab51fc448932c2711cf71b1b4517 @tiendung tiendung committed Jun 8, 2011
Showing with 5 additions and 1 deletion.
  1. +5 −1 lib/mongoid_search/mongoid_search.rb
View
6 lib/mongoid_search/mongoid_search.rb
@@ -83,7 +83,11 @@ def search_relevant(query, options={})
collection.map_reduce(map, reduce, options)
end
end
-
+
+ def update_keywords!
+ update_attribute(:_keywords, set_keywords)
+ end
+
private
# TODO: This need some refactoring..

0 comments on commit f5ffec5

Please sign in to comment.