-
app/Domain/Mute/HasMutes.php
Open in GitHubuse Domain\User\Models\User; use Illuminate\Database\Eloquent\Builder; trait HasMutes { // public function scopeWhereMuted(Builder $builder, User $user): Builder { return $builder->whereHas('mutes', fn (Builder $builder) => $builder->whereUser($user)); } }