Skip to content

Commit 52b6027

Browse files
satoryuWaKeMaTTa
andauthored
Update lib/docx/document.rb
Co-Authored-By: Mohamed Ziata <wakematta@gmail.com>
1 parent 2050fe2 commit 52b6027

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/docx/document.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def initialize(path_or_io, options = {})
3131
end
3232

3333
document = @zip.find_entry('word/document.xml')
34-
document = @zip.find_entry('word/document2.xml') if document.nil?
34+
document ||= @zip.find_entry('word/document2.xml')
3535
raise Errno::ENOENT if document.nil?
3636

3737
@document_xml = document.get_input_stream.read

0 commit comments

Comments
 (0)