Review 11.5 Merged

73657[BUGFIX] Properly reset form renderable validators

waldhacker CR +2 V +2 Normal +76 −2 updated 02/24/22, 18:18

Commit message

Since form renderable validators are stored as SplObjectStorage
instances, it is currently impossible to properly reset those
validators, e.g. within a configured variant in the form configuration.
This is because detaching during a foreach over SplObjectStorage
instances updates the internal pointer. This leads to inconsistent
behavior in the foreach loop.

To come around this issue, a cloned SplObjectStorage is now used to
remove all currently registered validators, properly resetting all
validators for the form renderable. Additionally, this edge case is now
covered by a functional test case.

Review

  • Code review CR +2 Done
    • waldhacker +2
    • Helmut Hummel +1
  • Verified V +2 Done
    • waldhacker +2
    • Helmut Hummel +1
    • core-ci +1 CI

Issues 1

Files 3

Review log 57

  1. waldhacker commented on patch set 1 02/24/22, 17:17

    Cherry Picked from branch main.
  2. core-ci voted on patch set 1 V -1 02/24/22, 17:28 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/24208

  3. waldhacker commented on patch set 2 02/24/22, 17:33

    Published edit on patch set 1.
  4. core-ci voted on patch set 2 V +1 02/24/22, 17:42 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/24209

  5. Helmut Hummel voted on patch set 2 V +1 CR +1 02/24/22, 18:06

  6. waldhacker voted on patch set 2 V +2 CR +2 02/24/22, 18:18

  7. waldhacker merged patch set 3 02/24/22, 18:18