bug #10675 [Validator] Fix constraint violation message parameterization

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | maybe
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #10675
| License       | MIT

This PR fixes an error during the constraint violation message parametrization, more information on the related ticket.