Issue #3605995: Drupal 11 fatal TypeError in WebformWorkflowsElementState::create()

Fixes the fatal TypeError reported in this issue.

Cause

The Views filter injects the plugin.manager.views.join service, whose class is Drupal\views\Plugin\ViewsHandlerManager. The $joinManager property was typed Drupal\views\Plugin\ViewsPluginManager, which is a sibling class (both extend DefaultPluginManager), not a parent. Assigning the join manager in create() therefore threw a fatal TypeError, and every View using the "Webform workflows element state" filter crashed before rendering.

Fix

Type the property (and its import) as ViewsHandlerManager, the actual class of the injected service. One file changed, four lines.

Credit

Diagnosis and proposed fix by wschwab in the issue.

Merge request reports

Loading