From 024fdf9c1aa535a4772d25772684ddfe6c582be7 Mon Sep 17 00:00:00 2001 From: Franck Date: Fri, 7 Oct 2022 16:04:39 +0200 Subject: [PATCH] call static instead of self on protected method --- src/PhpWord/Shared/Html.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/PhpWord/Shared/Html.php b/src/PhpWord/Shared/Html.php index ad5aec11..96caff76 100644 --- a/src/PhpWord/Shared/Html.php +++ b/src/PhpWord/Shared/Html.php @@ -61,7 +61,7 @@ class Html * @todo parse $stylesheet for default styles. Should result in an array based on id, class and element, * which could be applied when such an element occurs in the parseNode function. */ - self::$options = $options; + static::$options = $options; // Preprocess: remove all line ends, decode HTML entity, // fix ampersand and angle brackets and add body tag for HTML fragments @@ -82,10 +82,10 @@ class Html $dom = new DOMDocument(); $dom->preserveWhiteSpace = $preserveWhiteSpace; $dom->loadXML($html); - self::$xpath = new DOMXPath($dom); + static::$xpath = new DOMXPath($dom); $node = $dom->getElementsByTagName('body'); - self::parseNode($node->item(0), $element); + static::parseNode($node->item(0), $element); if (\PHP_VERSION_ID < 80000) { libxml_disable_entity_loader($orignalLibEntityLoader); }