lib/rocketio/controller/render/template_vars.rb in rocketio-0.1.0 vs lib/rocketio/controller/render/template_vars.rb in rocketio-0.2.0

- old
+ new

@@ -15,15 +15,15 @@ def self.define_template_vars_methods source = self return unless source.instance_variables.include?(:@__template_vars__) vars = source.instance_variable_get(:@__template_vars__).each_with_object(allocate.__template_vars__.dup) do |(name,value),o| o[name] = :"__#{name}_template_var__" if value.is_a?(Proc) - private_api << define_method(o[name], &value) + api.delete define_method(o[name], &value) else - private_api << define_method(o[name]) {value} + api.delete define_method(o[name]) {value} end end.freeze - private_api << define_method(:__template_vars__) {vars} + api.delete define_method(:__template_vars__) {vars} end def __template_vars__; RocketIO::EMPTY_HASH end def template_vars