Browse Source

[backend] Emails : log des erreurs d'envoi liées à Mailjet

refactoring
Guillaume Bourgeois 5 years ago
parent
commit
40a01865ae
1 changed files with 9 additions and 1 deletions
  1. +9
    -1
      backend/models/MailForm.php

+ 9
- 1
backend/models/MailForm.php View File

$response = $mj->post(\Mailjet\Resources::$Email, ['body' => $body]); $response = $mj->post(\Mailjet\Resources::$Email, ['body' => $body]);
} }
return $response->success() ;
$success = $response->success() ;
if($success) {
return true ;
}
else {
Yii::error($response->getBody(), 'Mailjet');
return false ;
}
} }


} }

Loading…
Cancel
Save