Check out subscription in admin and start_date has changed:
Expected behavior
Shouldn't change start_date if you are just editing a subscription
Actual behavior
Updates start_date to current time
Product impact
Does this issue affect WooCommerce Subscriptions? yes
Does this issue affect WooCommerce Payments? tbc
Additional context
Possible solution is to add $creating as below to start_date if statement within method prepare_object_for_database in class-wc-rest-subscriptions-controller.php, as when not creating and not setting the start_date in cURL json above, then the start_date is reset to now.
Describe the bug
If I push an update to a subscription via the API, it changes start_date to the current time.
To Reproduce
With an existing subscription
Run cURL command (as per https://woocommerce.github.io/subscriptions-rest-api-docs/#update-a-subscription)
Check out subscription in admin and start_date has changed:
Expected behavior
Shouldn't change start_date if you are just editing a subscription
Actual behavior
Updates start_date to current time
Product impact
Additional context
Possible solution is to add $creating as below to start_date if statement within method
prepare_object_for_database
inclass-wc-rest-subscriptions-controller.php
, as when not creating and not setting the start_date in cURL json above, then the start_date is reset to now.