Skip to content
This repository has been archived by the owner on Apr 15, 2019. It is now read-only.

Commit

Permalink
write the entries of the zip file only if it is a file
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Stämpfli committed Apr 19, 2012
1 parent d338f30 commit a82f2a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/docx_manipulator.rb
Expand Up @@ -33,7 +33,7 @@ def process

Zip::ZipOutputStream.open(target) do |os|
Zip::ZipFile.foreach(source) do |entry|
unless files_to_be_written.include?(entry.name)
if !files_to_be_written.include?(entry.name) && entry.file?
os.put_next_entry entry.name
os.write entry.get_input_stream.read
end
Expand Down

0 comments on commit a82f2a2

Please sign in to comment.