Skip to content
Snippets Groups Projects

Drupal 11 compatibility

2 files
+ 3
4
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -22,7 +22,7 @@ class LinkWithText extends CKEditorPluginBase implements CKEditorPluginConfigura
* {@inheritdoc}
*/
public function getFile() {
return drupal_get_path('module', 'ckeditor_link_with_text') . '/js/plugins/linktext/plugin.js';
return \Drupal::service('extension.list.module')->getPath('ckeditor_link_with_text') . '/js/plugins/linktext/plugin.js';
}
/**
@@ -45,7 +45,7 @@ class LinkWithText extends CKEditorPluginBase implements CKEditorPluginConfigura
* {@inheritdoc}
*/
public function getButtons() {
$path = drupal_get_path('module', 'ckeditor_link_with_text') . '/js/plugins/linktext';
$path = \Drupal::service('extension.list.module')->getPath('ckeditor_link_with_text') . '/js/plugins/linktext';
return [
'internalLinkButton' => [
'label' => t('Internal Link'),
Loading