Problem/Motivation

This is a simple way to improve one of the most common error messages in entityreference:

The referenced entity for @field_label field (@type: @id) is invalid

With many referenced fields it may be hard to understand which field we're talking about.

Steps to reproduce

Trigger the error, for example adding a reference to article A in article B, and then deleting article A.

Proposed resolution

Improve the message like this

The referenced entity for @field_label field (@type: @id) is invalid.

Remaining tasks

Testing.

User interface changes

Better error message.

API changes

None.

Data model changes

None.

CommentFileSizeAuthor
field_label.patch822 bytesmarco

Comments

marco created an issue. See original summary.

marco’s picture

Title: Add field label » Add field label to error message