Replaced unspecific mixed datatype in PluginBase.php class

Created on 14 January 2020, over 4 years ago
Updated 11 November 2023, 7 months ago

The data type of the $plugin_definition constructor parameter is array. However, it is defined in the PHPDoc block as "mixed". That's unspecific and does not help any developer. Also this is deprecated in the Drupal coding standards.

See the following PHP class: docroot/core/lib/Drupal/Component/Plugin/PluginBase.php

πŸ“Œ Task
Status

Needs work

Version

11.0 πŸ”₯

Component
DocumentationΒ  β†’

Last updated about 3 hours ago

No maintainer
Created by

πŸ‡©πŸ‡ͺGermany Christian Bonk

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • The Needs Review Queue Bot β†’ tested this issue. It either no longer applies to Drupal core, or fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".

    Apart from a re-roll or rebase, this issue may need more work to address feedback in the issue or MR comments. To progress an issue, incorporate this feedback as part of the process of updating the issue. This helps other contributors to know what is outstanding.

    Consult the Drupal Contributor Guide β†’ to find step-by-step guides for working with issues.

  • πŸ‡ΊπŸ‡ΈUnited States shelane

    Setting the docblock with @param array $plugin_definition won't work either because it will end up with a phpcs message of:

    phpcs: @param annotation of method class::__construct() does not specify type hint for items of its traversable parameter $plugin_definition.

Production build 0.69.0 2024