[TASK] Dont create a Controller class if no actions are defined

Resolves: #57687
Releases: 6.2

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