Refactored cleaner config code.