lib/danica/variables_holder/variables_builder.rb in danica-2.4.4 vs lib/danica/variables_holder/variables_builder.rb in danica-2.5.0
- old
+ new
@@ -28,16 +28,10 @@
private
def add_setter(name)
instance.send(:define_method, "#{name}=") do |value|
- if(containers_hash[name.to_sym].try(:container?))
- containers_hash[name.to_sym].content = wrap_value(value)
- else
- value = wrap_value(value)
- value = Danica::Wrapper::Container.new value unless value.container?
- containers_hash[name.to_sym] = value
- end
+ containers_hash[name.to_sym].content = wrap_value(value)
end
end
def add_reader(name)
instance.send(:define_method, name) do