Comment vérifier l'unicité tout en poussant des valeurs dans le tableau en utilisant Angular JS?

  $scope.displayyears = [];
  $scope.Joinyear = function(display) {
    $scope.yeardisplay = display;       
    $scope.yeardisp = $scope.displayyears.push($scope.yeardisplay);
    $scope.displayyearss = uniq($scope.yeardisp)
  }

il déclenche une erreur comme "uniq est pas défini"..Comment on vérifie l'unicité??

source d'informationauteur Bharani