diff options
| author | Randy Morgan <[email protected]> | 2012-04-01 11:58:09 +0900 |
|---|---|---|
| committer | Randy Morgan <[email protected]> | 2012-04-01 11:58:09 +0900 |
| commit | 1529fce32449a8454208fded20d83c9ceca810e0 (patch) | |
| tree | 02f722182fea58a51b8c0a5433221b3a677e80e4 /lib/axlsx/rels | |
| parent | 22a341841f191a5aa00e87b1f166b4f25cc67f0a (diff) | |
| download | caxlsx-1529fce32449a8454208fded20d83c9ceca810e0.tar.gz caxlsx-1529fce32449a8454208fded20d83c9ceca810e0.zip | |
rebuild all serialization to use string concatenation instead of nokogiri.
Diffstat (limited to 'lib/axlsx/rels')
| -rw-r--r-- | lib/axlsx/rels/relationship.rb | 2 | ||||
| -rw-r--r-- | lib/axlsx/rels/relationships.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/axlsx/rels/relationship.rb b/lib/axlsx/rels/relationship.rb index 4321c7e1..89a09ce1 100644 --- a/lib/axlsx/rels/relationship.rb +++ b/lib/axlsx/rels/relationship.rb @@ -51,7 +51,7 @@ module Axlsx # @param [String] str # @param [Integer] rId the id for this relationship # @return [String] - def to_xml_string(str = '', rId) + def to_xml_string(rId, str = '') h = self.instance_values h[:Id] = 'rId' << rId.to_s str << '<Relationship ' diff --git a/lib/axlsx/rels/relationships.rb b/lib/axlsx/rels/relationships.rb index 06bd4934..e0d6ea13 100644 --- a/lib/axlsx/rels/relationships.rb +++ b/lib/axlsx/rels/relationships.rb @@ -14,7 +14,7 @@ require 'axlsx/rels/relationship.rb' def to_xml_string(str = '') str << '<?xml version="1.0" encoding="UTF-8"?>' str << '<Relationships xmlns="' << RELS_R << '">' - each_with_index { |rel, index| rel.to_xml_string(str, index+1) } + each_with_index { |rel, index| rel.to_xml_string(index+1, str) } str << '</Relationships>' end # Serializes the relationships document. |
