mirror of https://github.com/MISP/MISP
fix: [internal] return true from the external email sender if no mocking is happening instead of the full email
parent
db3ac8acc5
commit
8418e8ee57
|
@ -777,11 +777,16 @@ class User extends AppModel
|
|||
}
|
||||
}
|
||||
$Email->attachments($attachments);
|
||||
$mock = false;
|
||||
if (Configure::read('MISP.disable_emailing') || !empty($params['mock'])) {
|
||||
$Email->transport('Debug');
|
||||
$mock = true;
|
||||
}
|
||||
$result = $Email->send($params['body']);
|
||||
$Email->reset();
|
||||
if ($result && !$mock) {
|
||||
return true;
|
||||
}
|
||||
return $result;
|
||||
}
|
||||
return false;
|
||||
|
|
Loading…
Reference in New Issue