Code Duplication    Length = 5-5 lines in 2 locations

src/Modules/Extractors/ContentExtractor.php 2 locations

@@ 131-135 (lines=5) @@
128
     * @param array $nodeCandidates
129
     */
130
    private function updateBestNodeCandidates(Element $node, $nodeCandidates) {
131
        if (!in_array($node->parent(), $nodeCandidates, true)) {
132
            if ($node->parent() instanceof Element) {
133
                $nodeCandidates[] = $node->parent();
134
            }
135
        }
136
137
        if ($node->parent() instanceof Element) {
138
            if (!in_array($node->parent()->parent(), $nodeCandidates, true)) {
@@ 138-142 (lines=5) @@
135
        }
136
137
        if ($node->parent() instanceof Element) {
138
            if (!in_array($node->parent()->parent(), $nodeCandidates, true)) {
139
                if ($node->parent()->parent() instanceof Element) {
140
                    $nodeCandidates[] = $node->parent()->parent();
141
                }
142
            }
143
        }
144
145
        return $nodeCandidates;