Problem/Motivation

If entity doesn't have route_provider, error occurs in renderCommentField when $provider is not checked before usage.

Steps to reproduce

This can be reproduced for example with a webform and allowing submissions to have field as explained in https://drupal.stackexchange.com/a/308771. Then in webform submission page comment is added, the error occurs, $handler is null.

Proposed resolution

Check route_providers before usage.

Remaining tasks

Patch to be checked.

User interface changes

No.

API changes

No.

Data model changes

No.

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

MikaT created an issue. See original summary.

mikat’s picture

Patch.

avpaderno’s picture

Version: 8.x-1.0-beta5 » 8.x-1.x-dev
Issue tags: -Bug report

I am removing a used issue tag, as Bug report is already a Category value.

pilulu’s picture

Status: Active » Reviewed & tested by the community

Works for me ! Thanks

idebr made their first commit to this issue’s fork.

idebr’s picture

Status: Reviewed & tested by the community » Fixed

Committed, thanks!

  • idebr committed fe950447 on 8.x-1.x
    Issue #3398748 by idebr, MikaT, Pilulu: Entity without route_provider...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.