Skip to content

Commit

Permalink
fix: solves #88
Browse files Browse the repository at this point in the history
  • Loading branch information
Marcuzz committed Apr 3, 2024
1 parent b0f0f3e commit d3f2710
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ Alternatively you could look into using WooCommerce "Early renewals": [https://d
= Not released yet =
* Added: A warning for when you select Vipps as your brand when your currency is not set to NOK.
* Fixed: Frontend admin localization.
* Fixed: A fatal error that could occur when calling `get_agreement_id_from_order` when handling renewals. Reported and diagnosed by magnuskl on GitHub.

= 1.20.1 =
* Fixed: Frontend scripts were not properly loaded.
Expand Down
2 changes: 1 addition & 1 deletion includes/wc-vipps-recurring-helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ public static function get_agreement_id_from_order( $order ) {
return $agreement_id;
}

$subscriptions = wcs_get_subscriptions_for_order( $order );
$subscriptions = wcs_get_subscriptions_for_order( $order, [ 'order_type' => 'any' ] );
$subscription = array_shift( $subscriptions );

return self::get_meta( $subscription, self::META_AGREEMENT_ID );
Expand Down

0 comments on commit d3f2710

Please sign in to comment.