Run Rector on your code to see what it can do for you:

Config  rector.php
Rector version: d7710f - released at 2023-10-03 09:39