From f636f55c1eebed33673fb72b2ff53acfd825733d Mon Sep 17 00:00:00 2001 From: Joshua Franks Date: Wed, 10 Jun 2020 15:56:33 +0100 Subject: [PATCH] wip --- src/Models/Campaign.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Models/Campaign.php b/src/Models/Campaign.php index 06dab787..ff023fe7 100644 --- a/src/Models/Campaign.php +++ b/src/Models/Campaign.php @@ -38,7 +38,7 @@ public function getActiveSubscriberCountAttribute(): int ->whereNull('unsubscribed_at') ->when(!$this->send_to_all, function (Builder $query) { $query->whereHas('segments', function (Builder $subQuery) { - $subQuery->whereIn('id', $this->segments->pluck('id')); + $subQuery->whereIn('segments.id', $this->segments->pluck('id')); }); }) ->count();