- Issue created by @xandermar
- πΊπΈUnited States xandermar Milton, Delaware
Similar issue:
https://www.drupal.org/project/commerce_pricelist/issues/3353428#:~:text... π Call to undefined function drupal_get_path() with D10 Fixed ()%20no%20longer%20exists%20with,be%20able%20to%20support%20D10.
- Status changed to Needs review
over 1 year ago 8:38pm 6 December 2023 - πΊπΈUnited States xandermar Milton, Delaware
Patch created that updates the code...
diff --git a/src/Plugin/CKEditorPlugin/Markdown.php b/src/Plugin/CKEditorPlugin/Markdown.php index b5c771e..992cbab 100644 --- a/src/Plugin/CKEditorPlugin/Markdown.php +++ b/src/Plugin/CKEditorPlugin/Markdown.php @@ -19,7 +19,7 @@ class Markdown extends CKEditorPluginBase { * {@inheritdoc} */ public function getButtons() { - $path = $this->getModulePath('ckeditor_markdown') . '/js/plugins/markdown'; + $path = \Drupal::service('extension.list.module')->getPath('ckeditor_markdown') . '/js/plugins/markdown'; return [ 'Markdown' => [ 'label' => $this->t('Markdown'), @@ -32,7 +32,7 @@ class Markdown extends CKEditorPluginBase { * {@inheritdoc} */ public function getFile() { - return $this->getModulePath('ckeditor_markdown') . '/js/plugins/markdown/plugin.js'; + return \Drupal::service('extension.list.module')->getPath('ckeditor_markdown') . '/js/plugins/markdown/plugin.js'; } /**
- Status changed to Closed: duplicate
5 months ago 8:22am 15 November 2024