function tfa_basic_tfa_enabled_body in TFA Basic plugins 7
Returns text appropriate for an email when someone has enabled tfa.
Parameters
array $message: The message, must include the language.
array $params: Parameters from drupal_mail. Must include the account.
Return value
string Message body.
1 call to tfa_basic_tfa_enabled_body()
- tfa_basic_mail in ./
tfa_basic.module - Implements hook_mail().
File
- ./
tfa_basic.module, line 768
Code
function tfa_basic_tfa_enabled_body($message, $params) {
$text = t("[user:name],\n\nThanks for configuring two-factor authentication on your @site_name account!\n\nThis additional level of security will help to ensure that only you are able to log in to your account.\n\nIf you ever lose the device you configured, you should act quickly to delete its association with this account.\n\n-- @site_name team", array(
'@site_name' => variable_get('site_name', 'Drupal'),
));
return token_replace($text, array(
'user' => $params['account'],
), array(
'language' => $message['language'],
'sanitize' => FALSE,
'clear' => TRUE,
));
}