perform some code cleanup