ParticipationPolicy fix viewWonList

This commit is contained in:
Jérémy Munsch 2023-12-20 13:12:54 +01:00
parent de748bb9bb
commit 2ef26bc270
No known key found for this signature in database
GPG key ID: 18361AF3BFEC0FEC

View file

@ -70,7 +70,7 @@ class ParticipationPolicy
public function viewWonList(Customer $authUser): bool
{
return (bool)$authUser->participations()->where(fn (Builder $q) =>
$q->whereHas('product')->orWhereHas('discount'))->count();
$q->whereHas('instantWin')->orWhereHas('discount'))->count();
}
/**