Some more clean up code