From b50a098f422cdb671a67ccb41e2837aa505e405b Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Sun, 9 May 2021 22:07:51 +0200 Subject: Remove erroneous call to optional_node_child(). Just after this we loop over all nodes, and optional_node_child will raise an exception if there is more than one. --- src/lib/text_content.cc | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src/lib') diff --git a/src/lib/text_content.cc b/src/lib/text_content.cc index 4ba2de348..5ae8dd45e 100644 --- a/src/lib/text_content.cc +++ b/src/lib/text_content.cc @@ -104,10 +104,6 @@ TextContent::from_xml (Content* parent, cxml::ConstNodePtr node, int version) return { make_shared(parent, node, version) }; } - if (!node->optional_node_child("Text")) { - return {}; - } - list> c; for (auto i: node->node_children("Text")) { c.push_back (make_shared(parent, i, version)); -- cgit v1.2.3