mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-20 08:22:17 +00:00
add config cis_send_profil_update_mails, use it in profil update controllers
This commit is contained in:
@@ -47,6 +47,8 @@ class ProfilUpdate extends FHCAPI_Controller
|
||||
'show' => self::PERM_LOGGED,
|
||||
]);
|
||||
|
||||
$this->load->config('cis');
|
||||
|
||||
// Load language phrases
|
||||
$this->loadPhrases(
|
||||
array(
|
||||
@@ -504,6 +506,11 @@ class ProfilUpdate extends FHCAPI_Controller
|
||||
|
||||
private function sendEmail_onProfilUpdate_insertion($uid, $profil_update_id, $topic)
|
||||
{
|
||||
$this->addMeta('cis_send_profil_update_mails', $this->config->item('cis_send_profil_update_mails'));
|
||||
if($this->config->item('cis_send_profil_update_mails') === false)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
$this->load->helper('hlp_sancho_helper');
|
||||
$emails = [];
|
||||
@@ -573,6 +580,11 @@ class ProfilUpdate extends FHCAPI_Controller
|
||||
|
||||
private function sendEmail_onProfilUpdate_response($uid, $topic, $status)
|
||||
{
|
||||
if($this->config->item('cis_send_profil_update_mails') === false)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
$this->load->helper('hlp_sancho_helper');
|
||||
$email = $uid . "@" . DOMAIN;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user