From e54562b6d4b657d99f52ca067b3ff842b865bae5 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Wed, 10 Mar 2021 20:32:38 +1100 Subject: [PATCH] Only one confirmation per user signup --- app/Jobs/Account/CreateAccount.php | 12 ++++++------ app/Listeners/SendVerificationNotification.php | 3 ++- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/app/Jobs/Account/CreateAccount.php b/app/Jobs/Account/CreateAccount.php index f9131b004870..96f04399b8aa 100644 --- a/app/Jobs/Account/CreateAccount.php +++ b/app/Jobs/Account/CreateAccount.php @@ -102,13 +102,13 @@ class CreateAccount // $nmo->to_user = $spaa9f78; // $nmo->settings = $sp035a66->settings; - $nmo = new NinjaMailerObject; - $nmo->mailable = new NinjaMailer((new VerifyUserObject($spaa9f78, $sp035a66))->build()); - $nmo->company = $sp035a66; - $nmo->to_user = $spaa9f78; - $nmo->settings = $sp035a66->settings; + // $nmo = new NinjaMailerObject; + // $nmo->mailable = new NinjaMailer((new VerifyUserObject($spaa9f78, $sp035a66))->build()); + // $nmo->company = $sp035a66; + // $nmo->to_user = $spaa9f78; + // $nmo->settings = $sp035a66->settings; - NinjaMailerJob::dispatch($nmo); + // NinjaMailerJob::dispatch($nmo); // NinjaMailerJob::dispatchNow($nmo); diff --git a/app/Listeners/SendVerificationNotification.php b/app/Listeners/SendVerificationNotification.php index a8d4836bbfcf..8c84b22ef874 100644 --- a/app/Listeners/SendVerificationNotification.php +++ b/app/Listeners/SendVerificationNotification.php @@ -46,7 +46,8 @@ class SendVerificationNotification implements ShouldQueue */ public function handle($event) { - + nlog("In Send Verification Notification"); + MultiDB::setDB($event->company->db); $event->user->service()->invite($event->company);