Skip to content

Commit 74116a4

Browse files
committed
Remove impossible condition
The parent's child must exist because otherwise this node could not have a parent node.
1 parent 1fc2ddc commit 74116a4

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

ext/dom/parentnode/tree.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -684,12 +684,6 @@ static zend_result dom_child_removal_preconditions(const xmlNode *child, int str
684684
return FAILURE;
685685
}
686686

687-
xmlNodePtr children = child->parent->children;
688-
if (!children) {
689-
php_dom_throw_error(NOT_FOUND_ERR, stricterror);
690-
return FAILURE;
691-
}
692-
693687
return SUCCESS;
694688
}
695689

0 commit comments

Comments
 (0)