Cleanup: refactoring