| Conditions | 2 |
| Paths | 2 |
| Total Lines | 10 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 7 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 25 | 1 | protected function normalizeElement(DOMElement $if) |
|
| 26 | { |
||
| 27 | 1 | $choose = $this->createElement('xsl:choose'); |
|
| 28 | 1 | $when = $choose->appendChild($this->createElement('xsl:when')); |
|
| 29 | 1 | $when->setAttribute('test', $if->getAttribute('test')); |
|
| 30 | 1 | while ($if->firstChild) |
|
| 31 | { |
||
| 32 | 1 | $when->appendChild($if->firstChild); |
|
| 33 | } |
||
| 34 | 1 | $if->parentNode->replaceChild($choose, $if); |
|
| 35 | } |
||
| 36 | } |