Conditions | 5 |
Paths | 4 |
Total Lines | 15 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
19 | public function hasChildNodes() |
||
20 | { |
||
21 | $children = $this->childNodes; |
||
22 | if (!($children instanceof DOMNodeList) || $children->length === 0) { |
||
23 | return false; |
||
24 | } |
||
25 | |||
26 | foreach ($children as $child) { |
||
27 | if ($child->nodeType === XML_ELEMENT_NODE) { |
||
28 | return true; |
||
29 | } |
||
30 | } |
||
31 | |||
32 | return false; |
||
33 | } |
||
34 | } |
||
35 |