Displaying 1 result from an estimated 1 matches for "inherited_without_controller_helper".
2008 Mar 03
0
A kind of monkey patch and an invitation for criticism for all you (who know this stuff better than I do)
...ontroller_helper_module.send(:include, helper_module)
        recreate_controller_helper_object
        add_template_helper_without_controller_helper(helper_module)
      end
      alias_method_chain :add_template_helper, :controller_helper
      def inherited_with_controller_helper(child)
        inherited_without_controller_helper(child)
        child.controller_helper_module.send :include,
controller_helper_module
        child.recreate_controller_helper_object
      end
      alias_method_chain :inherited, :controller_helper
      def recreate_controller_helper_object
        self.controller_helper_object = Object.new...