From: Alexander Ebert Date: Mon, 22 Jan 2024 17:14:35 +0000 (+0100) Subject: Improve the docs X-Git-Tag: 6.0.7_dev_1~7^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=998eefd4c5de1f125f12b11f2525257e0cf52a13;p=GitHub%2FWoltLab%2FWCF.git Improve the docs --- diff --git a/wcfsetup/install/files/lib/system/html/node/HtmlNodePlainLink.class.php b/wcfsetup/install/files/lib/system/html/node/HtmlNodePlainLink.class.php index 3d949e9d52..726c0dc675 100644 --- a/wcfsetup/install/files/lib/system/html/node/HtmlNodePlainLink.class.php +++ b/wcfsetup/install/files/lib/system/html/node/HtmlNodePlainLink.class.php @@ -186,8 +186,8 @@ class HtmlNodePlainLink $next = $this->findBr($this->link, 'nextSibling'); $previous = $this->findBr($this->link, 'previousSibling'); - // If multiple links are in the same paragraph, the `topLevelParent` link to old parent in the DOM - // and have to be found again. + // When multiple links are in the same paragraph, `topLevelParent` + // may no longer be a valid reference. if ($this->topLevelParent->parentElement === null) { $this->topLevelParent = $this->link; while ($this->topLevelParent->parentNode->nodeName !== 'body') { @@ -202,8 +202,8 @@ class HtmlNodePlainLink $previous = $this->findBr($parent, 'previousSibling'); } - // Link is the only content in the top level parent. - // This will happen, when in one paragraph are multiple links. + // The link is the only content in the top level parent. This + // can happen when there are multiple links within one paragraph. if ($next === null && $previous === null) { $this->topLevelParent->parentNode->insertBefore($this->link, $this->topLevelParent); DOMUtil::removeNode($this->topLevelParent);