Skip to content
Snippets Groups Projects
Commit 2709041c authored by Fredrik Jonsson's avatar Fredrik Jonsson
Browse files

Prefer composer installed PHP Markdown if installed.

parent ba5cb3a0
No related branches found
No related tags found
No related merge requests found
......@@ -81,7 +81,7 @@ class Markdown extends FilterBase {
$text = $converter->convertToHtml($text);
break;
case 'php-markdown':
if (\Drupal::moduleHandler()->moduleExists('libraries')) {
if (!class_exists('Michelf\MarkdownExtra') && \Drupal::moduleHandler()->moduleExists('libraries')) {
libraries_load('php-markdown', 'markdown-extra');
}
$text = MarkdownExtra::defaultTransform($text);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment