Remove $context properties from ConstraintValidators

Created on 13 March 2024, 9 months ago
Updated 28 March 2024, 8 months ago

Problem/Motivation

In CommentNameConstraintValidator, EntityTestCompositeConstraintValidator and EntityTestEntityLevelValidator there is the following declaration:

  /**
   * Validator 2.5 and upwards compatible execution context.
   *
   * @var \Symfony\Component\Validator\Context\ExecutionContextInterface
   */
  protected $context;

The parent property is correctly typed already. Symfony 7 adds an actual typehint here, which causes type issues.

Steps to reproduce

Proposed resolution

Remove the property and rely on the parent class.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

πŸ“Œ Task
Status

Fixed

Version

10.3 ✨

Component
BaseΒ  β†’

Last updated about 13 hours ago

Created by

πŸ‡¬πŸ‡§United Kingdom longwave UK

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024