private function removeNodesWithNegativeScores(Element $topNode): self {
        if (!empty($topNode)) {
            $gravityItems = $topNode->find('*[gravityScore]');

            foreach ($gravityItems as $item) {
                $score = (int)$item->attr('gravityScore');

                if ($score < 1) {
                    $item->remove();
                }
            }
        }

        return $this;
    }