From c76bd55de1f1e4657a4368972e5d8572ab0b29fd Mon Sep 17 00:00:00 2001 From: David Bomba Date: Wed, 22 Feb 2023 09:49:11 +1100 Subject: [PATCH] Run mailer syncronously --- app/Services/Ledger/LedgerService.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/Services/Ledger/LedgerService.php b/app/Services/Ledger/LedgerService.php index 9d9935fc5e02..d03945ad21db 100644 --- a/app/Services/Ledger/LedgerService.php +++ b/app/Services/Ledger/LedgerService.php @@ -35,7 +35,7 @@ class LedgerService $this->entity->company_ledger()->save($company_ledger); - ClientLedgerBalanceUpdate::dispatch($this->entity->company, $this->entity->client)->delay(now()->addSeconds(rand(30, 300))); + ClientLedgerBalanceUpdate::dispatch($this->entity->company, $this->entity->client)->delay(rand(3, 13)); return $this; } @@ -51,7 +51,7 @@ class LedgerService $this->entity->company_ledger()->save($company_ledger); - ClientLedgerBalanceUpdate::dispatch($this->entity->company, $this->entity->client)->delay(now()->addSeconds(rand(30, 300))); + ClientLedgerBalanceUpdate::dispatch($this->entity->company, $this->entity->client)->delay(rand(3, 13)); return $this; } @@ -67,7 +67,7 @@ class LedgerService $this->entity->company_ledger()->save($company_ledger); - ClientLedgerBalanceUpdate::dispatch($this->entity->company, $this->entity->client)->delay(now()->addSeconds(rand(30, 300))); + ClientLedgerBalanceUpdate::dispatch($this->entity->company, $this->entity->client)->delay(rand(3, 13)); return $this; }