From 7dd380d2e0c4724e6acc6371fa68d9a819503602 Mon Sep 17 00:00:00 2001 From: Jonathan Vollebregt Date: Mon, 26 Aug 2024 04:01:16 +0200 Subject: [PATCH] SimpleXMLElementPlugin: Coverage tweak --- src/Parser/SimpleXMLElementPlugin.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/Parser/SimpleXMLElementPlugin.php b/src/Parser/SimpleXMLElementPlugin.php index 5430617cb..07e2a9019 100644 --- a/src/Parser/SimpleXMLElementPlugin.php +++ b/src/Parser/SimpleXMLElementPlugin.php @@ -195,7 +195,7 @@ protected function getAttributeRepresentation(SimpleXMLElementValue $element, Si * * So let's just give up and stick to aliases because fuck that mess! */ - protected function getChildrenRepresentation(SimpleXMLElementValue $element, SimpleXMLElement $var): ?Representation + protected function getChildrenRepresentation(SimpleXMLElementValue $element, SimpleXMLElement $var): Representation { $parser = $this->getParser(); $namespaces = \array_merge(['' => null], $var->getDocNamespaces()); @@ -243,11 +243,7 @@ protected function getChildrenRepresentation(SimpleXMLElementValue $element, Sim } } - if ($c->contents) { - return $c; - } - - return null; + return $c; } /**