Bug fix for view model