Started code cleanup - in progress