Project:
UbercartCategory:
feature requestPriority:
normalStatus:
fixedWhen a payment fails, there is currently no log of the reason. This makes debugging difficult. It would be helpful to have a watchdog log entry that has a description of the failure. The following patch to uc_payment.module beta 4 provides this feature:
***************
*** 886,895 ****
--- 886,900 ----
if (!empty($result['uid'])) {
$result['uid'] = 0;
}
uc_payment_enter($order_id, $method, $amount, $result['uid'],
$result['data'], $result['comment']);
+ } else {
+ // payment failed. Generate a watchdog
+ watchdog('uc_payment', $result['message']
+ . "<b>uid:</b> " . $message['uid'],
+ WATCHDOG_WARNING);
}
if (!empty($result['message']) && !$default) {
drupal_set_message($result['message']);
}
Re: Payment failure needs a watchdog to log the reason
Good idea. Added to core.