Class: ThinkingSphinx::ActiveRecord::Callbacks::UpdateCallbacks

Inherits:
Callbacks
  • Object
show all
Defined in:
lib/thinking_sphinx/active_record/callbacks/update_callbacks.rb

Instance Attribute Summary

Attributes inherited from Callbacks

#instance

Instance Method Summary collapse

Methods inherited from Callbacks

callbacks, #initialize

Constructor Details

This class inherits a constructor from ThinkingSphinx::Callbacks

Instance Method Details

#after_updateObject



6
7
8
9
10
11
12
# File 'lib/thinking_sphinx/active_record/callbacks/update_callbacks.rb', line 6

def after_update
  return unless updates_enabled?

  indices.each do |index|
    update index unless index.distributed?
  end
end