Merge pull request #506 from kalvn/master

Avoids populating a markdown empty container if there's no description.
This commit is contained in:
Arthur 2016-03-01 12:15:22 +01:00
commit 40b25bef6a
1 changed files with 4 additions and 1 deletions

View File

@ -173,7 +173,10 @@ function process_markdown($description)
->setBreaksEnabled(true)
->text($processedDescription);
$processedDescription = sanitize_html($processedDescription);
$processedDescription = '<div class="markdown">'. $processedDescription . '</div>';
if(!empty($processedDescription)){
$processedDescription = '<div class="markdown">'. $processedDescription . '</div>';
}
return $processedDescription;
}