mirror of
https://github.com/erusev/parsedown.git
synced 2025-01-17 04:38:29 +01:00
Merge pull request #676 from aidantwoods/fix/uninitialized-string-offset
Fix access to potentially uninitialised offset
This commit is contained in:
commit
2bd7113c55
@ -1480,7 +1480,7 @@ class Parsedown
|
||||
|
||||
protected function inlineSpecialCharacter($Excerpt)
|
||||
{
|
||||
if ($Excerpt['text'][1] !== ' ' and strpos($Excerpt['text'], ';') !== false
|
||||
if (substr($Excerpt['text'], 1, 1) !== ' ' and strpos($Excerpt['text'], ';') !== false
|
||||
and preg_match('/^&(#?+[0-9a-zA-Z]++);/', $Excerpt['text'], $matches)
|
||||
) {
|
||||
return array(
|
||||
|
Loading…
x
Reference in New Issue
Block a user