refactor to simplify
cleanup