diff -u b/includes/output.inc b/includes/output.inc --- b/includes/output.inc +++ b/includes/output.inc @@ -145,6 +145,7 @@ * @see t() */ function dt($string, $args = array()) { + $output = NULL; if (function_exists('t') && drush_drupal_version() == 7) { $output = t($string, $args); } @@ -152,12 +153,16 @@ if (function_exists('drupal_classloader')) { drupal_classloader(); } - $output = t($string, $args); + if (function_exists('t')) { + $output = t($string, $args); + } } - else if (drush_drupal_version() <= 7 && function_exists('theme')) { + else if (function_exists('t') && drush_drupal_version() <= 7 && function_exists('theme')) { $output = t($string, $args); } - else { + + // If Drupal's t() function unavailable. + if (is_null($output)) { if (!empty($args)) { $output = strtr($string, $args); }