Skip to content

Commit

Permalink
Fix HHVM error getgrav#344
Browse files Browse the repository at this point in the history
  • Loading branch information
rhukster committed Oct 7, 2015
1 parent e593381 commit 0f4c65f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion system/src/Grav/Common/Helpers/Truncator.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public static function truncate($html, $length, $opts=array())
// We'll only be able to parse HTML5 if it's valid XML
$doc = new DOMDocument('4.01', 'utf-8');
$doc->formatOutput = false;
$doc->preserveWhitespace = true;
$doc->preserveWhiteSpace = true;
// loadHTML will fail with HTML5 tags (article, nav, etc)
// so we need to suppress errors and if it fails to parse we
// retry with the XML parser instead
Expand Down

0 comments on commit 0f4c65f

Please sign in to comment.