Did more refactoring.