Skip to content

Commit

Permalink
Merge pull request #235 from ved-beejadhur-cko/ECPINT-2797
Browse files Browse the repository at this point in the history
ECPINT-2798: handle save card in case subscription plugin is not present
  • Loading branch information
ved-beejadhur-cko authored Aug 11, 2021
2 parents b744f06 + 8a81ae0 commit 98c046b
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,9 @@ public function process_payment( $order_id )
}

// save source id for subscription
WC_Checkoutcom_Subscription::save_source_id($order_id, $order, $result['source']['id']);
if (class_exists(WC_Subscriptions_Order)) {
WC_Checkoutcom_Subscription::save_source_id($order_id, $order, $result['source']['id']);
}

// Set action id as woo transaction id
update_post_meta($order_id, '_transaction_id', $result['action_id']);
Expand Down

0 comments on commit 98c046b

Please sign in to comment.