clean up and fix