Verified Commit dd8e580c authored by Korko's avatar Korko
Browse files

Remove Org Final Recap sending

parent debbc52b
Pipeline #369289 failed with stages
in 1 minute and 49 seconds
......@@ -6,7 +6,6 @@ use App\Models\Draw;
use App\Exceptions\SolverException;
use App\Jobs\SendMail;
use App\Models\Mail as MailModel;
use App\Mail\OrganizerFinalRecap;
use App\Mail\OrganizerRecap;
use App\Mail\TargetDrawn;
use App\Models\Participant;
......@@ -49,7 +48,6 @@ class DrawHandler
}
$this->sendOrganizerEmail($draw);
$this->sendDelayedOrganizerEmail($draw);
foreach ($draw->participants as $participant) {
$this->sendParticipantEmail($participant);
}
......@@ -117,12 +115,6 @@ class DrawHandler
SendMail::dispatch($draw->organizer, new OrganizerRecap($draw));
}
public function sendDelayedOrganizerEmail(Draw $draw)
{
SendMail::dispatch($draw->organizer, new OrganizerFinalRecap($draw))
->delay($draw->expires_at->addDay());
}
public function sendParticipantEmail(Participant $participant)
{
Metrics::increment('email');
......
......@@ -4,7 +4,6 @@ namespace Tests\Unit;
use App\Exceptions\SolverException;
use App\Jobs\SendMail;
use App\Mail\OrganizerFinalRecap;
use App\Mail\OrganizerRecap;
use App\Mail\TargetDrawn;
use App\Models\Draw;
......@@ -85,7 +84,6 @@ class DrawHandlerTest extends TestCase
$this->assertHasMailPushed(OrganizerRecap::class, 'test@test.com', function ($m) use (&$link) {
$link = $m->panelLink;
});
$this->assertHasMailPushed(OrganizerFinalRecap::class, 'test@test.com');
// TODO: assert body
// Ensure Participants receive their own recap
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment