Skip to content

Instantly share code, notes, and snippets.

View jtanium's full-sized avatar

Jason Edwards jtanium

  • Salt Lake City, Utah
View GitHub Profile
# Written by MattBrown found at https://gist.github.com/659188
class BackgroundSessionProxy < Sunspot::SessionProxy::AbstractSessionProxy
class <<self
def async?
!!Thread.current[:background_session_proxy_async]
end
def with_async
self.async = true
begin