Error:

Fatal error: Call to undefined function userpoints_ubercart_refund() in /var/www/html/sites/all/modules/userpoints_ubercart/uc_userpoints_payment.module on line 154

When: Deleting an order.

To solve, it needs to alter in uc_userpoints_payment.module, lines 148 and 154:

		case 'update':
			// if the order is canceled we need to refund thier points because we are too lazy to do it by hand...
			if ($arg2 == 'canceled') {
				if (strtolower($order->payment_method) == 'points') {
-					userpoints_ubercart_refund($order);
+					uc_userpoints_payment_refund($order);
				}
			}
			break;
		case 'delete':	
		  if (strtolower($order->payment_method) == 'points') {
-				userpoints_ubercart_refund($order);
+				uc_userpoints_payment_refund($order);
	  	}
		  break;

Comments

bmagistro’s picture

Status: Needs review » Fixed

Thanks for catching that. Orders usually aren't deleted and I have a feeling I just overlooked that due to other settings in my sandbox. It should be fixed in the latest dev version.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.