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

Fix warning spew

This commit is contained in:
Yehuda Katz 2009-10-06 22:36:14 -10:00
parent 6361d4234c
commit e57197a967

View file

@ -236,7 +236,9 @@ module ActionView #:nodoc:
# they are in AC.
if controller.class.respond_to?(:_helper_serial)
klass = @views[controller.class._helper_serial] ||= Class.new(self) do
Subclasses.const_set(controller.class.name.gsub(/::/, '__'), self)
name = controller.class.name.gsub(/::/, '__')
Subclasses.remove_const(name) if Subclasses.const_defined?(name)
Subclasses.const_set(name, self)
if controller.respond_to?(:_helpers)
include controller._helpers