Removed unnecessary $rootScope.$apply