Review main Merged

86952[BUGFIX] Display correct method for callable event listeners

Oli Bartsch CR +2 V +2 Easy +7 −1 updated 11/12/24, 07:56

Commit message

In case an event listener is not registered
with a `method`, it's treated as callable
by the ListenerProvider and therefore its
`__invoke()` method is called.

For such cases, the configuration module
displayed `method =`, which is misleading
as this might look like the listener
registration is broken.

Therefore, the configuration module now
displays `method = __invoke` in case a
listener is used as callable (does not
define a  dedicated method in the
registration).

Review

  • Code review CR +2 Done
    • Oli Bartsch +2
    • Garvin Hicking +1
    • Andreas Kienast +1
  • Verified V +2 Done
    • Oli Bartsch +2
    • Garvin Hicking +1
    • Andreas Kienast +1
    • core-ci +1 CI

Issues 1

Files 1

Review log 68

  1. Oli Bartsch uploaded patch set 1 11/11/24, 12:29

  2. core-ci voted on patch set 1 V +1 11/11/24, 12:35 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/69305

  3. Andreas Kienast updated the commit message in patch set 2 V +1 11/11/24, 12:53

  4. Andreas Kienast voted on patch set 2 CR +1 V +1 11/11/24, 12:53

  5. core-ci voted on patch set 2 V +1 11/11/24, 13:00 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/69306

  6. Garvin Hicking commented on patch set 2 CR +1 V +1 11/11/24, 20:55

    personally I can better grok foreach than areay_walks but all the same :)
  7. Oli Bartsch commented on patch set 2 CR +2 V +2 11/12/24, 07:56

    Reply

    Actually not exactly the same. `foreach` has some drawbacks like polluting the value of a variable to the outside. See for reference: https://gist.github.com/Potherca/640471e0e9918b803feb5d1b0ff788ef
  8. Oli Bartsch merged patch set 3 11/12/24, 07:56