code: public function slugify($text)
      {
          $slugged = $this->slugify->slugify($text);
  
          $count = 1;
          $orig = $slugged;
          while (in_array($slugged, $this->used)) {
              $slugged = $orig . '-' . $count;
              $count++;
          }
  
          $this->used[] = $slugged;
          return $slugged;
      }
docs: Slugify
  
  @param string $text
  @return string