Send email when SendReminders finishes

This commit is contained in:
Hillel Coren 2017-01-31 13:33:46 +02:00
parent 6371339805
commit 2cdf369c04

View File

@ -80,6 +80,14 @@ class SendReminders extends Command
} }
$this->info('Done'); $this->info('Done');
if ($errorEmail = env('ERROR_EMAIL')) {
\Mail::raw('EOM', function ($message) use ($errorEmail) {
$message->to($errorEmail)
->from(CONTACT_EMAIL)
->subject('SendReminders: Finished successfully');
});
}
} }
/** /**