1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-08 20:22:42 +01:00

Minor fixes for events for invoice was emailed

This commit is contained in:
David Bomba 2023-03-13 16:51:03 +11:00
parent a3c03039b7
commit 148456b70d

View File

@ -214,13 +214,11 @@ class SendReminders implements ShouldQueue
nlog('firing email');
EmailEntity::dispatch($invitation, $invitation->company, $template)->delay(10);
event(new InvoiceWasEmailed($invoice->invitations->first(), $invoice->company, Ninja::eventVars(), $template));
}
});
if ($this->checkSendSetting($invoice, $template)) {
event(new InvoiceWasEmailed($invoice->invitations->first(), $invoice->company, Ninja::eventVars(), $template));
}
$invoice->last_sent_date = now();
$invoice->next_send_date = $this->calculateNextSendDate($invoice);