Problem/Motivation

When submitting the config form for a text format I get the following error:

AssertionError: Schema errors: Array ( [editor.editor.id_does_not_matter:settings.plugins.ckeditor5_mentions_mention.dropdown_limit] => variable type is string but applied schema class is Drupal\Core\TypedData\Plugin\DataType\IntegerData [editor.editor.id_does_not_matter:settings.plugins.ckeditor5_mentions_mention.mention_feeds_enabled.select] => variable type is integer but applied schema class is Drupal\Core\TypedData\Plugin\DataType\StringData ) in assert() (line 729 of core/modules/ckeditor5/src/Plugin/Editor/CKEditor5.php).

Steps to reproduce

Enable the module, navigate to a text format and click save.

Proposed resolution

Fix the values saved in Mention::submitConfigurationForm to match the schema.

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

zrpnr created an issue. See original summary.

zrpnr’s picture

Status: Active » Needs review

Added an MR to cast the values on submit.

sujan shrestha’s picture

Version: 1.1.0 » 2.0.x-dev
Status: Needs review » Fixed

Fixed in 2.0.x (commit f3512a1, release 2.0.1), along the lines of MR !1. The plugin settings are saved with the types required by the schema: integer dropdown limit, list of enabled feed IDs, integer commit keys. A post update repairs settings already stored by older versions. Thanks @zrpnr.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.