Minor refactoring to enable better transition