function scn_mail in Simple Comment Notify 8
Implements hook_mail().
File
- ./
scn.module, line 22 - Main file for the scn module.
Code
function scn_mail($key, &$message, $params) {
switch ($key) {
case 'new_comment':
$message['from'] = \Drupal::config('system.site')
->get('mail');
$message['subject'] = t('New comment on @siteName', [
'@siteName' => \Drupal::config('system.site')
->get('name'),
]);
$message['body'][] = t('Link to the new comment :linkToComment', [
':linkToComment' => $params['url'],
]);
break;
}
}