aboutsummaryrefslogtreecommitdiff
path: root/mammoth/docx/__init__.py
diff options
context:
space:
mode:
Diffstat (limited to 'mammoth/docx/__init__.py')
-rw-r--r--mammoth/docx/__init__.py15
1 files changed, 10 insertions, 5 deletions
diff --git a/mammoth/docx/__init__.py b/mammoth/docx/__init__.py
index 58bfa50..0579d09 100644
--- a/mammoth/docx/__init__.py
+++ b/mammoth/docx/__init__.py
@@ -29,11 +29,16 @@ def read(fileobj, external_file_access=False):
external_file_access=external_file_access,
)
- return results.combine([
- _read_notes(read_part_with_body, part_paths),
- _read_comments(read_part_with_body, part_paths),
- ]).bind(lambda referents:
- _read_document(read_part_with_body, notes=referents[0], comments=referents[1], part_paths=part_paths)
+ return results.combine_obj(
+ notes=_read_notes(read_part_with_body, part_paths),
+ comments=_read_comments(read_part_with_body, part_paths),
+ ).bind(lambda referents:
+ _read_document(
+ read_part_with_body,
+ notes=referents.notes,
+ comments=referents.comments,
+ part_paths=part_paths,
+ )
)