mirror of
https://github.com/erusev/parsedown.git
synced 2023-08-10 21:13:06 +03:00
paragraph doesn't have to use a type
This commit is contained in:
parent
b8d1cfe91a
commit
0820d0a607
@ -226,7 +226,7 @@ class Parsedown
|
||||
|
||||
# ~
|
||||
|
||||
if ($CurrentBlock['type'] === 'Paragraph' and ! isset($CurrentBlock['interrupted']))
|
||||
if (isset($CurrentBlock) and ! isset($CurrentBlock['type']) and ! isset($CurrentBlock['interrupted']))
|
||||
{
|
||||
$CurrentBlock['element']['text'] .= "\n".$text;
|
||||
}
|
||||
@ -236,10 +236,7 @@ class Parsedown
|
||||
|
||||
$CurrentBlock = $this->buildParagraph($Line);
|
||||
|
||||
$CurrentBlock += array(
|
||||
'type' => 'Paragraph',
|
||||
'identified' => true,
|
||||
);
|
||||
$CurrentBlock['identified'] = true;
|
||||
}
|
||||
}
|
||||
|
||||
@ -568,7 +565,7 @@ class Parsedown
|
||||
|
||||
protected function identifySetext($Line, array $Block = null)
|
||||
{
|
||||
if ( ! isset($Block) or $Block['type'] !== 'Paragraph' or isset($Block['interrupted']))
|
||||
if ( ! isset($Block) or isset($Block['type']) or isset($Block['interrupted']))
|
||||
{
|
||||
return;
|
||||
}
|
||||
@ -646,7 +643,7 @@ class Parsedown
|
||||
|
||||
protected function identifyTable($Line, array $Block = null)
|
||||
{
|
||||
if ( ! isset($Block) or $Block['type'] !== 'Paragraph' or isset($Block['interrupted']))
|
||||
if ( ! isset($Block) or isset($Block['type']) or isset($Block['interrupted']))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user