diff --git a/.changeset/rude-penguins-live.md b/.changeset/rude-penguins-live.md new file mode 100644 index 00000000..daf4ae9c --- /dev/null +++ b/.changeset/rude-penguins-live.md @@ -0,0 +1,5 @@ +--- +"@rebilly/client-php": patch +--- + +fix(api-definitions): Add missing locale in Customer.yaml Rebilly/rebilly#8662 diff --git a/src/Model/Customer.php b/src/Model/Customer.php index 8e1e29ed..b7e3cf84 100644 --- a/src/Model/Customer.php +++ b/src/Model/Customer.php @@ -89,6 +89,9 @@ public function __construct(array $data = []) if (array_key_exists('organizationId', $data)) { $this->setOrganizationId($data['organizationId']); } + if (array_key_exists('locale', $data)) { + $this->setLocale($data['locale']); + } if (array_key_exists('taxNumbers', $data)) { $this->setTaxNumbers($data['taxNumbers']); } @@ -301,6 +304,18 @@ public function getOrganizationId(): ?string return $this->fields['organizationId'] ?? null; } + public function getLocale(): ?string + { + return $this->fields['locale'] ?? null; + } + + public function setLocale(null|string $locale): static + { + $this->fields['locale'] = $locale; + + return $this; + } + /** * @return null|TaxNumber[] */ @@ -422,6 +437,9 @@ public function jsonSerialize(): array if (array_key_exists('organizationId', $this->fields)) { $data['organizationId'] = $this->fields['organizationId']; } + if (array_key_exists('locale', $this->fields)) { + $data['locale'] = $this->fields['locale']; + } if (array_key_exists('taxNumbers', $this->fields)) { $data['taxNumbers'] = $this->fields['taxNumbers'] !== null ? array_map(