Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
final SearchObserver
class SearchObserver < ActiveRecord::Observer
observe :topic, :post, :user, :category
def after_save(obj)
obj.update_search_data_index
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment