$value */ public function validate(string $attribute, mixed $value, Closure $fail): void { $ids = array_unique(Arr::wrap($value)); if ($ids && app(SongRepository::class)->getMany(ids: $ids, scopedUser: $this->user)->count() !== count($ids)) { $fail('Not all songs or episodes exist in the database or are accessible by the user.'); } } }