updated to reflect refactoring