Fixed code for navigation

Both views now will handle navigation properly