Before refactoring viewmodel