Skip to content

Commit e4e241c

Browse files
committed
Remove dependency on ext-tidy
1 parent 9fd67db commit e4e241c

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

composer.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@
1717
"php": ">=5.3",
1818
"react/event-loop": "~0.4.0|~0.3.0",
1919
"clue/buzz-react": "~0.2.0",
20-
"ext-simplexml": "*",
21-
"ext-tidy": "*"
20+
"ext-simplexml": "*"
2221
},
2322
"require-dev": {
2423
"clue/block-react": "~0.1.0"

src/Io/Loader.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ public function loadXmlFile($path)
1313

1414
public function loadXmlString($html)
1515
{
16-
// clean up HTML to safe XML
17-
$html = tidy_repair_string($html, array(
18-
'output-xml' => true,
19-
'input-xml' => true,
20-
));
16+
// fix invalid markup of help link in footer of outdated ViewVC versions
17+
$html = str_replace('Help</strong></td>', 'Help</a></strong></td>', $html);
18+
19+
// replace unneeded HTML entities
20+
$html = str_replace('&nbsp;', ' ', $html);
2121

2222
// clean up namespace declaration
2323
$html = str_replace('xmlns="', 'ns="', $html);

0 commit comments

Comments
 (0)