existBySlug($slug)) { return $slug; } $number++; } } }