[BUGFIX] Avoid error in EXT.Direct

Resolves: #55337
Releases: 6.0, 6.1, 6.2

Change-Id: I45f1545a890f7de2b12aaec35f80374f48921a0b
Reviewed-on: https://review.typo3.org/27057
Reviewed-by: Nico de Haen
Tested-by: Nico de Haen