Sha256: 224e631da3945bcfd027dfc899d2c05ef5bfa5b268cf5f14c2acb42933e16664
Contents?: true
Size: 674 Bytes
Versions: 12
Compression:
Stored size: 674 Bytes
Contents
module Sunspot #:nodoc: module Rails #:nodoc: # # This module adds an after_filter to ActionController::Base that commits # the Sunspot session if any documents have been added, changed, or removed # in the course of the request. # module RequestLifecycle class <<self def included(base) #:nodoc: base.after_filter do if Sunspot::Rails.configuration.auto_commit_after_request? Sunspot.commit_if_dirty elsif Sunspot::Rails.configuration.auto_commit_after_delete_request? Sunspot.commit_if_delete_dirty end end end end end end end
Version data entries
12 entries across 12 versions & 2 rubygems