refactor and cleanup
cleanup