cleaner refactor