Refactor for clean.