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

Config  rector.php
Rector version: dev-main@84eb4a released at 2023-02-02 17:49