Minor fixes for reminders
This commit is contained in:
parent
61b0308a6f
commit
5544207687
|
|
@ -99,7 +99,7 @@ class EmailEntity implements ShouldQueue
|
||||||
*
|
*
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function handle()
|
public function handle() :void
|
||||||
{
|
{
|
||||||
/* Don't fire emails if the company is disabled */
|
/* Don't fire emails if the company is disabled */
|
||||||
if ($this->company->is_disabled) {
|
if ($this->company->is_disabled) {
|
||||||
|
|
|
||||||
|
|
@ -136,7 +136,7 @@ class ReminderJob implements ShouldQueue
|
||||||
(Ninja::isSelfHost() || $invoice->company->account->isPaidHostedClient())) {
|
(Ninja::isSelfHost() || $invoice->company->account->isPaidHostedClient())) {
|
||||||
|
|
||||||
$invoice->invitations->each(function ($invitation) use ($invoice, $reminder_template) {
|
$invoice->invitations->each(function ($invitation) use ($invoice, $reminder_template) {
|
||||||
EmailEntity::dispatchSync($invitation, $invitation->company, $reminder_template);
|
EmailEntity::dispatch($invitation, $invitation->company, $reminder_template);
|
||||||
nlog("Firing reminder email for invoice {$invoice->number} - {$reminder_template}");
|
nlog("Firing reminder email for invoice {$invoice->number} - {$reminder_template}");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue