Cleanup and some changes ready for php version switching