Skip to content
This repository was archived by the owner on May 21, 2025. It is now read-only.

Fix get related order IDs method #624

Merged
merged 6 commits into from
May 24, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
*** WooCommerce Subscriptions Core Changelog ***

= 7.1.2 - xxxx-xx-xx =
* Fix - Added a check for the format when listing related subscription orders.

= 7.1.1 - 2024-05-09 =
* Fix - Resolved an issue that caused "WC_DateTime could not be converted to int" warnings to occur on non-hpos sites while editing a subscription.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,9 @@ public function get_related_order_ids_from_cache( $subscription, $relation_type

$meta_data = $this->get_related_order_metadata( $subscription, $relation_type );

return $meta_data ? maybe_unserialize( $meta_data->meta_value ) : '';
$related_orders = $meta_data ? maybe_unserialize( $meta_data->meta_value ) : '';

return is_array( $related_orders ) ? $related_orders : '';
}

/**
Expand Down