Project

General

Profile

« Previous | Next » 

Revision f39bfd77

Added by Ohad Levy almost 12 years ago

  • ID f39bfd77b58289c919444412d63ed09e451da561

minor cleanups for cache invalidations

View differences:

app/controllers/application_controller.rb
before_filter :welcome, :only => :index, :unless => :api_request?
before_filter :authorize
cache_sweeper :topbar_sweeper
cache_sweeper :topbar_sweeper, :unless => :api_request?
def welcome
@searchbar = true
app/controllers/topbar_sweeper.rb
private
def expire_cache_for(record)
expire_fragment("tabs_and_title_records-#{User.current.id}")
expire_fragment("tabs_and_title_records-#{User.current.id}") if User.current
end
end

Also available in: Unified diff