Incorrect dblog entry when using an email widget field
jajathejazzcat - August 12, 2009 - 12:31
| Project: | Field Actions |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Description
The function fieldactions_send_email_to_email_action creates a dblog entry of 'Sent email to %node_owner_mail', when it should be the email address entered into an email widget field.
So in line 523,
<?php
if (drupal_mail('fieldactions_general', 'fieldactions_mail_to_email', $field_value['email'], $language, $params, $from, TRUE)) {
watchdog('fieldactions', 'Sent email to %recipient', array('%recipient' => $vars['%node_owner_mail']));
}
else {
watchdog('error', 'Unable to send email to %recipient', array('%recipient' => $vars['%node_owner_mail']));
}
?>should be changed to
<?php
if (drupal_mail('fieldactions_general', 'fieldactions_mail_to_email', $field_value['email'], $language, $params, $from, TRUE)) {
watchdog('fieldactions', 'Sent email to %recipient', array('%recipient' => $field_value['email']));
}
else {
watchdog('error', 'Unable to send email to %recipient', array('%recipient' => $field_value['email']));
}
?>
#1
Here is a patch.
#2
committed to HEAD and DRUPAL-6--1
#3
Automatically closed -- issue fixed for 2 weeks with no activity.