cleaned up code, to do list