1
0
Fork 0
mirror of synced 2024-06-02 19:04:49 +12:00

Skip mail when no SMTP hostname set

This commit is contained in:
Eldad Fux 2020-11-21 01:44:00 +02:00
parent 63e442293c
commit ffdfc36229

View file

@ -1,6 +1,7 @@
<?php
use Utopia\App;
use Utopia\CLI\Console;
require_once __DIR__.'/../init.php';
@ -23,6 +24,11 @@ class MailsV1
{
global $register;
if(empty(App::getEnv('_APP_SMTP_HOST'))) {
Console::info('Skipped mail. No SMTP server hostname has been set.');
return;
}
$event = $this->args['event'];
$from = $this->args['from'];
$recipient = $this->args['recipient'];