diff --git a/includes/class-vindi-payment.php b/includes/class-vindi-payment.php index 930e686..c9ad608 100755 --- a/includes/class-vindi-payment.php +++ b/includes/class-vindi-payment.php @@ -94,6 +94,10 @@ public function get_customer() $currentUser = wp_get_current_user(); $email = $this->order->get_billing_email(); + if(isset($_GET['pay_for_order'])){ + $currentUser = get_user_by('ID', $this->order->get_user_id()); + } + $address = array( 'street' => $this->order->get_billing_address_1(), 'number' => $this->order->get_meta( '_billing_number' ),