Stores with Square and Subscriptions running currently get the following deprecated notice:
PHP Deprecated: Hook wcs_renewal_order_meta is deprecated since version wcs-core 2.5.0! Use wc_subscriptions_renewal_order_data instead. in /public/wp-includes/functions.php on line 6078
We should update this hook to the new one wc_subscriptions_renewal_order_data. There will need to be minor changes as the form of the passed data is slightly different.
To reproduce
Install and enable WooCommerce Subscriptions
Create a subscription product"
Products > Add new.
Select "Simple Subscription".
Enter a price.
Save.
Purchase the subscription using Square.
On the admin dashboard go to WooCommerce > Subscriptions.
From the actions drop down select "Process renewal".
Save the subscription to run the action.
Check your error logs, you should see the following notice:
PHP Deprecated: Hook wcs_renewal_order_meta is <strong>deprecated</strong> since version wcs-core 2.5.0! Use wc_subscriptions_renewal_order_data instead. in /app/public/wp-includes/functions.php on line 6085
Describe the bug
Stores with Square and Subscriptions running currently get the following deprecated notice:
From my search, Square still uses the
wcs_renewal_order_meta
hook here: https://github.com/woocommerce/woocommerce-square/blob/414e4126291bd85efdbae37c34890cd574491a6c/includes/Framework/PaymentGateway/Integrations/Payment_Gateway_Integration_Subscriptions.php#L96We should update this hook to the new one
wc_subscriptions_renewal_order_data
. There will need to be minor changes as the form of the passed data is slightly different.To reproduce