I guess $scope.studentInfo would be defined here because you assigned it to $rootScope in the badgesController?