Check $parts variable for false value (#400)
This currently throws a `TypeError` if `$parts` is `false`, which is a valid return value for `preg_split`.
This commit is contained in:
parent
dbb995733d
commit
98b12b84b1
1 changed files with 1 additions and 1 deletions
|
|
@ -499,7 +499,7 @@ class MarkdownExtra extends \Michelf\Markdown {
|
|||
$parsed .= $parts[0]; // Text before current tag.
|
||||
|
||||
// If end of $text has been reached. Stop loop.
|
||||
if (count($parts) < 3) {
|
||||
if ($parts === false || count($parts) < 3) {
|
||||
$text = "";
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue