(#27) angulars Controller function should be replaced with the ViewModel function