From 9dc18b3c5469f46542c09b17f82aa64d3375b308 Mon Sep 17 00:00:00 2001 From: scriptibus Date: Fri, 28 Feb 2020 17:37:01 +0100 Subject: [PATCH 1/2] Update UniqueEntity.rst The description of the message property implies that it is not possible to change the mapping of the error message. --- reference/constraints/UniqueEntity.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/reference/constraints/UniqueEntity.rst b/reference/constraints/UniqueEntity.rst index e229fb6447d..1f089f2529a 100644 --- a/reference/constraints/UniqueEntity.rst +++ b/reference/constraints/UniqueEntity.rst @@ -145,9 +145,9 @@ each with a single field. **type**: ``string`` **default**: ``This value is already used.`` -The message that's displayed when this constraint fails. This message is always -mapped to the first field causing the violation, even when using multiple fields -in the constraint. +The message that's displayed when this constraint fails. This message is by default +mapped to the first field causing the violation. When using multiple fields +in the constraint, the mapping can be specified in the `errorPath`_ property. Messages can include the ``{{ value }}`` placeholder to display a string representation of the invalid entity. If the entity doesn't define the From 694a911facd8c503683b6462a000fafd2ee69deb Mon Sep 17 00:00:00 2001 From: Lucas Nothnagel Date: Sun, 1 Mar 2020 17:23:01 +0100 Subject: [PATCH 2/2] Change wording 'in' to 'via' --- reference/constraints/UniqueEntity.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/reference/constraints/UniqueEntity.rst b/reference/constraints/UniqueEntity.rst index 1f089f2529a..3a7f3cbd007 100644 --- a/reference/constraints/UniqueEntity.rst +++ b/reference/constraints/UniqueEntity.rst @@ -147,7 +147,7 @@ each with a single field. The message that's displayed when this constraint fails. This message is by default mapped to the first field causing the violation. When using multiple fields -in the constraint, the mapping can be specified in the `errorPath`_ property. +in the constraint, the mapping can be specified via the `errorPath`_ property. Messages can include the ``{{ value }}`` placeholder to display a string representation of the invalid entity. If the entity doesn't define the