Details
-
Type: Bug
-
Status: Done/Fixed
-
Priority: Trivial
-
Resolution: Fixed/Completed
-
Affects Version/s: 2.1, 2.2.0
-
Fix Version/s: 2.2.0
-
Component/s: Drupal Integration Modules
-
Labels:None
Description
The watchdog function in drupal 6 already includes the translation of a message. Therefore it should not be called like its done for example in civicrm_group_roles.module:
$msg = t('Error: Unable to sync role @role', array('@role' => $role) );
watchdog('civicrm_group_roles', $msg);
if ($debug_mode) drupal_set_message($msg);
instead it should be more like:
$msg = 'Error: Unable to sync role @role';
$variables = array('@role' => $role);
watchdog('civicrm_group_roles', $msg, $variables);
if ($debug_mode) drupal_set_message(t($msg, $variables));
See api documentation: http://api.drupal.org/api/function/watchdog/6