_userpoints_transaction treats the moderate parameter correctly, when txn_id is not set, but ignores it when updating an txn_id.
Somebody familiar with the module, please check, whether other variables should be altered, before joinig the array.
Index: userpoints.module
===================================================================
--- userpoints.module (revision 762)
+++ userpoints.module (working copy)
@@ -735,6 +735,13 @@
$params['changed'] = $time;
if (is_numeric($params['txn_id'])) {
+ if ($params['moderate'] == true) {
+ $params['status'] = 1;
+ }
+ else {
+ $params['status'] = 0;
+ }
+
//A transaction ID was passed in so we'll update the transaction
$result = db_query("SELECT txn_id, uid, approver_uid, points,
time_stamp, status, operation, description, reference, expirydate, expired,
Comments
Comment #1
berdirThis is by design. moderate can only be used for new transactions, when updating existing transactions, you need to use status directly.