Skip to content

Commit

Permalink
Merge branch 'main' into patch-8
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeymike authored Feb 7, 2024
2 parents 50df41f + 1ea6936 commit 1712456
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Entities/Notification/NotificationSubscription.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
use Paddle\SDK\Entities\Shared\CollectionMode;
use Paddle\SDK\Entities\Shared\CurrencyCode;
use Paddle\SDK\Entities\Shared\CustomData;
use Paddle\SDK\Entities\Shared\ImportMeta;
use Paddle\SDK\Entities\Shared\TimePeriod;
use Paddle\SDK\Entities\Subscription\SubscriptionDiscount;
use Paddle\SDK\Entities\Subscription\SubscriptionItem;
Expand Down Expand Up @@ -46,6 +47,7 @@ protected function __construct(
public SubscriptionScheduledChange|null $scheduledChange,
public array $items,
public CustomData|null $customData,
public ImportMeta|null $importMeta,
) {
}

Expand Down Expand Up @@ -77,6 +79,7 @@ public static function from(array $data): self
: null,
items: array_map(fn (array $item): SubscriptionItem => SubscriptionItem::from($item), $data['items']),
customData: isset($data['custom_data']) ? new CustomData($data['custom_data']) : null,
importMeta: isset($data['import_meta']) ? ImportMeta::from($data['import_meta']) : null,
);
}
}

0 comments on commit 1712456

Please sign in to comment.