[TASK] Don't create closing php tags

Resolves: #57990
Releases: 6.2
Change-Id: I2858e89813056087b4cfe68e8e912e96c60647a1
Reviewed-on: https://review.typo3.org/29530
Reviewed-by: Nico de Haen
Tested-by: Nico de Haen