summaryrefslogtreecommitdiffhomepage
path: root/lib
diff options
context:
space:
mode:
authorRandy Morgan <[email protected]>2012-11-25 14:35:01 +0900
committerRandy Morgan <[email protected]>2012-11-25 14:35:01 +0900
commit727f2ca539ca0dadb72e0982256284736cc44076 (patch)
tree1f29f95899caf4103cd5acb184463b419e77374f /lib
parentbc256511fc600030746206f25b25d18385f5f2c2 (diff)
downloadcaxlsx-727f2ca539ca0dadb72e0982256284736cc44076.tar.gz
caxlsx-727f2ca539ca0dadb72e0982256284736cc44076.zip
Patched serilalized_element_attributes to properly update value from called block
Diffstat (limited to 'lib')
-rw-r--r--lib/axlsx/util/serialized_attributes.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/axlsx/util/serialized_attributes.rb b/lib/axlsx/util/serialized_attributes.rb
index 3372dd5c..30fcfaaa 100644
--- a/lib/axlsx/util/serialized_attributes.rb
+++ b/lib/axlsx/util/serialized_attributes.rb
@@ -65,7 +65,7 @@ module Axlsx
attrs.each do |attribute_name|
value = values[attribute_name.to_s]
next if value.nil?
- yield value if block_given?
+ value = yield value if block_given?
element_name = Axlsx.camel(attribute_name, false)
str << "<#{element_name}>#{value}</#{element_name}>"
end