aboutsummaryrefslogtreecommitdiff
path: root/mammoth/docx/document_xml.py
diff options
context:
space:
mode:
Diffstat (limited to 'mammoth/docx/document_xml.py')
-rw-r--r--mammoth/docx/document_xml.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/mammoth/docx/document_xml.py b/mammoth/docx/document_xml.py
index 8bfdd6f..9477ab5 100644
--- a/mammoth/docx/document_xml.py
+++ b/mammoth/docx/document_xml.py
@@ -1,4 +1,3 @@
-import os
import contextlib
from .. import documents
@@ -220,7 +219,7 @@ def _create_reader(numbering, content_types, relationships, styles, note_element
def _read_blip(element, alt_text):
relationship_id = element.attributes["r:embed"]
- image_path = os.path.join("word", relationships[relationship_id].target)
+ image_path = "word/" + relationships[relationship_id].target.lstrip("/")
content_type = content_types.find_content_type(image_path)
def open_image():