1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

fixed - warning: instance variable @controller not initialized

This commit is contained in:
Sandeep 2012-03-16 19:41:15 +05:30
parent 5245eb30b1
commit 5ae53d5cde

View file

@ -54,6 +54,11 @@ module ActionController #:nodoc:
class Sweeper < ActiveRecord::Observer #:nodoc:
attr_accessor :controller
def initialize(*args)
super
@controller = nil
end
def before(controller)
self.controller = controller
callback(:before) if controller.perform_caching