PluginProbe
Subscriptions for WooCommerce with Stripe Recurring Payments / 2.4.0
Subscriptions for WooCommerce with Stripe Recurring Payments v2.4.0
2.4.0 2.3.0 2.2.0 2.1.0 2.0.0 1.11.2 1.11.1 1.11.0 1.10.9 1.10.8 1.10.7 1.10.6 1.10.5 1.10.4 1.10.3 1.10.2 1.10.1 1.10.0 1.9.6 1.9.5 trunk 1.3.0 1.3.1 1.3.2 1.4.0 All 65 releases
← All changes | includes/Frontend/PlanCheckout.php +3 -1 2.0.0 → 2.4.0 View file →
@@ -255,9 +255,11 @@
255 255 update_post_meta( $subscription_id, '_subscrpt_timing_option', $timing_option );
256 256 update_post_meta( $subscription_id, '_subscrpt_price', (float) $order_item->get_meta( '_subscrpt_plan_price' ) );
257 257 update_post_meta( $subscription_id, '_subscrpt_plan_id', $plan_id );
258 258 update_post_meta( $subscription_id, '_subscrpt_plan_group_id', (int) $order_item->get_meta( '_subscrpt_plan_group_id' ) );
259 - update_post_meta( $subscription_id, '_subscrpt_user_cancel', $product->get_meta( '_subscrpt_user_cancel' ) );
259 + // Plans carry no cancellation setting, so fall back to the product default of allowing it.
260 + $user_cancel = $product->get_meta( '_subscrpt_user_cancel' );
261 + update_post_meta( $subscription_id, '_subscrpt_user_cancel', '' !== $user_cancel ? $user_cancel : 'yes' );
260 262 update_post_meta( $subscription_id, '_subscrpt_order_id', $order_item->get_order_id() );
261 263 update_post_meta( $subscription_id, '_subscrpt_order_item_id', $order_item->get_id() );
262 264 update_post_meta( $subscription_id, '_subscrpt_trial', $trial );
263 265