Skip to content

Commit

Permalink
πŸ› Fixes fivefilters#10 : Warning: Undefined array key 2
Browse files Browse the repository at this point in the history
  • Loading branch information
castroCrea authored Jan 3, 2023
1 parent 20bbc18 commit 1dd4141
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Readability.php
Original file line number Diff line number Diff line change
Expand Up @@ -1078,7 +1078,7 @@ private function unescapeHtmlEntities($str) {
}, $str);
$str = preg_replace_callback('/&#(?:x([0-9a-z]{1,4})|([0-9]{1,4}));/i', function ($matches) {
$hex = $matches[1];
$numStr = $matches[2];
$numStr = $matches[2] ?? '0';
if ($hex !== '') {
$num = intval($hex, 16);
} else {
Expand Down

0 comments on commit 1dd4141

Please sign in to comment.