Problem/Motivation

When we install the smartlinker_ai module and set up in CKEditor to enable plugin, then throws an error on the content format:

The website encountered an unexpected error. Try again later.

ArgumentCountError: Too few arguments to function Drupal\ai_ckeditor\AiCKEditorPluginBase::__construct(), 8 passed in /var/www/html/web/modules/contrib/smartlinker_ai/src/Plugin/AiCKEditor/SmartLinkerAI.php on line 86 and exactly 9 expected in Drupal\ai_ckeditor\AiCKEditorPluginBase->__construct() (line 77 of modules/contrib/ai_test/modules/ai_ckeditor/src/AiCKEditorPluginBase.php).

Steps to reproduce

1. Install required modules:
- AI Core
- AI CKEditor
2. Enable the 'smartlinker_ai' module
3. Go to '/admin/config/content/formats'
3. Click and configure 'Basic HTML' or 'Full HTML'
4. Throws an ArgumentCountError on that page

Please follow the screenshot for reference:
Argument error

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

ishani patel created an issue. See original summary.

ishani patel’s picture

Assigned: ishani patel » Unassigned
Status: Active » Needs review

Hello,
I've created MR,
Kindly review.

Thank you!

anjaliprasannan’s picture

StatusFileSize
new218.31 KB
new82.57 KB

I have reviewed fix and working fine. Code looks good. Hence moving to RTBC.

anjaliprasannan’s picture

Status: Needs review » Reviewed & tested by the community