Small change to "Modify docx file with rubyzip"

To make copy-pasting work :D
This commit is contained in:
peter50216 2016-03-28 09:41:50 +08:00
parent 3ec40d875d
commit 4d86978362
1 changed files with 1 additions and 1 deletions

View File

@ -218,7 +218,7 @@ buffer = Zip::OutputStream.write_buffer do |out|
out.write rels.to_xml(:indent => 0).gsub("\n","")
end
File.open(new_path, "w") {|f| f.write(buffer.string) }
File.open(new_path, "wb") {|f| f.write(buffer.string) }
```
## Configuration