You are here

function _emaillog_format_dblog_message in Logging and alerts 7

Same name and namespace in other branches
  1. 6 emaillog/emaillog.module \_emaillog_format_dblog_message()

Injects variables into dblog message and formats it for email subject.

1 call to _emaillog_format_dblog_message()
emaillog_mail in emaillog/emaillog.module
Implements hook_mail().

File

emaillog/emaillog.module, line 118
Drupal Module: Email Logging and Alerts

Code

function _emaillog_format_dblog_message($event) {
  if (empty($event['variables'])) {
    $message = strip_tags($event['message']);
  }
  else {
    $message = strip_tags(t($event['message'], $event['variables']));
  }
  return truncate_utf8($message, 60, TRUE, TRUE);
}