public
Description: I eat URLs. RAWRRRRR!
Clone URL: git://github.com/bottlecaplabs/zombieurl.git
skippy (author)
Fri Apr 11 12:10:24 -0700 2008
commit  d615b0f1f3cc42cb8e96cbf49e7bf6347251702f
tree    f90e93d9f5bd654e50c128752b8e51a37aea0f5b
parent  cce91402d68863bd1e8244bcd3baf5f5fd483109
zombieurl / app / controllers / application.rb
100644 15 lines (11 sloc) 0.491 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# Filters added to this controller apply to all controllers in the application.
# Likewise, all the methods added will be available for all controllers.
 
class ApplicationController < ActionController::Base
  # Pick a unique cookie name to distinguish our session data from others'
  session :session_key => '_zombie_url_session_id'
  
  before_filter :calculate_links
  
  # refactor to some sort of cache tool
  def calculate_links
    @cached_data = {:link_count => Link.count}
  end
end