From 62054f8b5b049fc6af727a1a80c22bf9b9466262 Mon Sep 17 00:00:00 2001 From: Stephen Ausman Date: Mon, 25 May 2020 09:06:52 -0500 Subject: [PATCH] fix: PHP 7.4 support (#42) Co-authored-by: Oleksandr Prypkhan --- README.md | 3 ++ lib/models/AccountInfo.php | 8 ++-- lib/models/AccountOAuthToken.php | 6 +-- lib/models/AddLabelLedgerEntryRequest.php | 2 +- lib/models/Address.php | 14 +++--- lib/models/Amount.php | 4 +- lib/models/AnswerKbaQuestionsRequest.php | 2 +- lib/models/AnswerKbaQuestionsResponse.php | 6 +-- lib/models/AnsweredKbaQuestion.php | 4 +- lib/models/ApplicationEvent.php | 12 ++--- lib/models/BeneficialOwnerListResponse.php | 6 +-- lib/models/BusinessClassification.php | 8 ++-- .../BusinessClassificationListResponse.php | 6 +-- lib/models/CatalogResponse.php | 4 +- lib/models/CertifyRequest.php | 2 +- lib/models/Clearing.php | 4 +- lib/models/CreateCustomer.php | 42 +++++++++--------- lib/models/CreateCustomerLabelRequest.php | 2 +- lib/models/CreateFundingSourceRequest.php | 16 +++---- lib/models/CreateOwnerRequest.php | 12 ++--- lib/models/CreateWebhook.php | 4 +- lib/models/Customer.php | 40 ++++++++--------- lib/models/CustomerListResponse.php | 6 +-- lib/models/CustomerOAuthToken.php | 6 +-- lib/models/Document.php | 14 +++--- lib/models/DocumentListResponse.php | 6 +-- lib/models/EventListResponse.php | 6 +-- lib/models/FacilitatorFeeRequest.php | 4 +- lib/models/FailureDetails.php | 4 +- lib/models/FeesBySourceResponse.php | 8 ++-- lib/models/FullAccountInfo.php | 12 ++--- lib/models/FundingSource.php | 28 ++++++------ lib/models/FundingSourceBalance.php | 10 ++--- lib/models/FundingSourceListResponse.php | 4 +- lib/models/HalLink.php | 6 +-- lib/models/IavToken.php | 6 +-- lib/models/KbaAnswer.php | 4 +- lib/models/KbaQuestion.php | 6 +-- lib/models/KbaQuestions.php | 8 ++-- lib/models/Label.php | 10 ++--- lib/models/LabelListResponse.php | 6 +-- lib/models/LabelReallocation.php | 6 +-- lib/models/LabelReallocationRequest.php | 4 +- lib/models/LedgerEntry.php | 10 ++--- lib/models/LedgerEntryListResponse.php | 6 +-- lib/models/MassPayment.php | 18 ++++---- lib/models/MassPaymentItem.php | 14 +++--- lib/models/MassPaymentItemListResponse.php | 6 +-- lib/models/MassPaymentItemRequestBody.php | 10 ++--- lib/models/MassPaymentListResponse.php | 6 +-- lib/models/MassPaymentRequestBody.php | 12 ++--- lib/models/MicroDeposits.php | 4 +- lib/models/MicroDepositsInitiated.php | 10 ++--- lib/models/Money.php | 4 +- lib/models/OAuthResponse.php | 14 +++--- lib/models/Owner.php | 16 +++---- lib/models/Ownership.php | 6 +-- lib/models/Passport.php | 4 +- lib/models/ProcessResult.php | 6 +-- lib/models/RemoveBankRequest.php | 2 +- lib/models/Transfer.php | 22 +++++----- lib/models/TransferFailure.php | 12 ++--- lib/models/TransferListResponse.php | 6 +-- lib/models/TransferRequestBody.php | 16 +++---- lib/models/UpdateBankRequest.php | 10 ++--- lib/models/UpdateCustomer.php | 44 +++++++++---------- lib/models/UpdateJobRequestBody.php | 2 +- lib/models/UpdateOwnerRequest.php | 12 ++--- lib/models/UpdateSubscription.php | 2 +- lib/models/UpdateTransfer.php | 2 +- lib/models/VerifyMicroDepositsRequest.php | 4 +- lib/models/Webhook.php | 16 +++---- lib/models/WebhookAttempt.php | 6 +-- lib/models/WebhookEventListResponse.php | 6 +-- lib/models/WebhookHeader.php | 4 +- lib/models/WebhookHttpRequest.php | 8 ++-- lib/models/WebhookHttpResponse.php | 8 ++-- lib/models/WebhookListResponse.php | 6 +-- lib/models/WebhookRetry.php | 8 ++-- .../WebhookRetryRequestListResponse.php | 6 +-- lib/models/WebhookSubscription.php | 12 ++--- 81 files changed, 367 insertions(+), 364 deletions(-) diff --git a/README.md b/README.md index 274897c..3c8ca10 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,9 @@ dwolla-swagger-php The new Dwolla API V2 SDK, as generated by [this fork of swagger-codegen](https://github.com/mach-kernel/swagger-codegen). +Additionally, temporary PHP 7.4 support was added using these replaces: + - `\$this\->([a-z0-9\_]+) = \$data\["([a-z0-9\_]+)"\]\;` into `\$this->$1 = \$data\["$2"\] ?? null;` + ## Version 1.3.0 diff --git a/lib/models/AccountInfo.php b/lib/models/AccountInfo.php index 39b851c..697f3e4 100644 --- a/lib/models/AccountInfo.php +++ b/lib/models/AccountInfo.php @@ -48,10 +48,10 @@ class AccountInfo implements ArrayAccess { public $_embedded; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->id = $data["id"]; - $this->name = $data["name"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->id = $data["id"] ?? null; + $this->name = $data["name"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/AccountOAuthToken.php b/lib/models/AccountOAuthToken.php index 355f427..6eea44a 100644 --- a/lib/models/AccountOAuthToken.php +++ b/lib/models/AccountOAuthToken.php @@ -45,9 +45,9 @@ class AccountOAuthToken implements ArrayAccess { public $token; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->token = $data["token"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->token = $data["token"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/AddLabelLedgerEntryRequest.php b/lib/models/AddLabelLedgerEntryRequest.php index c1d82c9..ccc8f71 100644 --- a/lib/models/AddLabelLedgerEntryRequest.php +++ b/lib/models/AddLabelLedgerEntryRequest.php @@ -39,7 +39,7 @@ class AddLabelLedgerEntryRequest implements ArrayAccess { public $amount; /* Amount */ public function __construct(array $data = null) { - $this->amount = $data["amount"]; + $this->amount = $data["amount"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Address.php b/lib/models/Address.php index 99ce380..2ff1f7a 100644 --- a/lib/models/Address.php +++ b/lib/models/Address.php @@ -57,13 +57,13 @@ class Address implements ArrayAccess { public $postal_code; /* string */ public function __construct(array $data = null) { - $this->address1 = $data["address1"]; - $this->address2 = $data["address2"]; - $this->address3 = $data["address3"]; - $this->city = $data["city"]; - $this->state_province_region = $data["state_province_region"]; - $this->country = $data["country"]; - $this->postal_code = $data["postal_code"]; + $this->address1 = $data["address1"] ?? null; + $this->address2 = $data["address2"] ?? null; + $this->address3 = $data["address3"] ?? null; + $this->city = $data["city"] ?? null; + $this->state_province_region = $data["state_province_region"] ?? null; + $this->country = $data["country"] ?? null; + $this->postal_code = $data["postal_code"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Amount.php b/lib/models/Amount.php index cb3ec84..eea82c5 100644 --- a/lib/models/Amount.php +++ b/lib/models/Amount.php @@ -42,8 +42,8 @@ class Amount implements ArrayAccess { public $currency; /* string */ public function __construct(array $data = null) { - $this->value = $data["value"]; - $this->currency = $data["currency"]; + $this->value = $data["value"] ?? null; + $this->currency = $data["currency"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/AnswerKbaQuestionsRequest.php b/lib/models/AnswerKbaQuestionsRequest.php index c7165be..8960fa9 100644 --- a/lib/models/AnswerKbaQuestionsRequest.php +++ b/lib/models/AnswerKbaQuestionsRequest.php @@ -39,7 +39,7 @@ class AnswerKbaQuestionsRequest implements ArrayAccess { public $answers; /* array[AnsweredKbaQuestion] */ public function __construct(array $data = null) { - $this->answers = $data["answers"]; + $this->answers = $data["answers"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/AnswerKbaQuestionsResponse.php b/lib/models/AnswerKbaQuestionsResponse.php index b8fba18..d96577b 100644 --- a/lib/models/AnswerKbaQuestionsResponse.php +++ b/lib/models/AnswerKbaQuestionsResponse.php @@ -45,9 +45,9 @@ class AnswerKbaQuestionsResponse implements ArrayAccess { public $_embedded; /* map[string,Number] */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->verification_status = $data["verification_status"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->verification_status = $data["verification_status"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/AnsweredKbaQuestion.php b/lib/models/AnsweredKbaQuestion.php index 193acac..be2a1f1 100644 --- a/lib/models/AnsweredKbaQuestion.php +++ b/lib/models/AnsweredKbaQuestion.php @@ -42,8 +42,8 @@ class AnsweredKbaQuestion implements ArrayAccess { public $answer_id; /* string */ public function __construct(array $data = null) { - $this->question_id = $data["question_id"]; - $this->answer_id = $data["answer_id"]; + $this->question_id = $data["question_id"] ?? null; + $this->answer_id = $data["answer_id"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/ApplicationEvent.php b/lib/models/ApplicationEvent.php index 627abd8..5584510 100644 --- a/lib/models/ApplicationEvent.php +++ b/lib/models/ApplicationEvent.php @@ -54,12 +54,12 @@ class ApplicationEvent implements ArrayAccess { public $resource_id; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->created = $data["created"]; - $this->topic = $data["topic"]; - $this->resource_id = $data["resource_id"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->created = $data["created"] ?? null; + $this->topic = $data["topic"] ?? null; + $this->resource_id = $data["resource_id"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/BeneficialOwnerListResponse.php b/lib/models/BeneficialOwnerListResponse.php index 11281ca..d450058 100644 --- a/lib/models/BeneficialOwnerListResponse.php +++ b/lib/models/BeneficialOwnerListResponse.php @@ -45,9 +45,9 @@ class BeneficialOwnerListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/BusinessClassification.php b/lib/models/BusinessClassification.php index 0bd7a7b..1a16563 100644 --- a/lib/models/BusinessClassification.php +++ b/lib/models/BusinessClassification.php @@ -48,10 +48,10 @@ class BusinessClassification implements ArrayAccess { public $name; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->name = $data["name"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->name = $data["name"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/BusinessClassificationListResponse.php b/lib/models/BusinessClassificationListResponse.php index 89be24f..47fd81d 100644 --- a/lib/models/BusinessClassificationListResponse.php +++ b/lib/models/BusinessClassificationListResponse.php @@ -45,9 +45,9 @@ class BusinessClassificationListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CatalogResponse.php b/lib/models/CatalogResponse.php index 3a82070..8315dee 100644 --- a/lib/models/CatalogResponse.php +++ b/lib/models/CatalogResponse.php @@ -42,8 +42,8 @@ class CatalogResponse implements ArrayAccess { public $_embedded; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CertifyRequest.php b/lib/models/CertifyRequest.php index 441a4dc..f7e673d 100644 --- a/lib/models/CertifyRequest.php +++ b/lib/models/CertifyRequest.php @@ -39,7 +39,7 @@ class CertifyRequest implements ArrayAccess { public $status; /* string */ public function __construct(array $data = null) { - $this->status = $data["status"]; + $this->status = $data["status"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Clearing.php b/lib/models/Clearing.php index 3041849..540c61d 100644 --- a/lib/models/Clearing.php +++ b/lib/models/Clearing.php @@ -42,8 +42,8 @@ class Clearing implements ArrayAccess { public $destination; /* string */ public function __construct(array $data = null) { - $this->source = $data["source"]; - $this->destination = $data["destination"]; + $this->source = $data["source"] ?? null; + $this->destination = $data["destination"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CreateCustomer.php b/lib/models/CreateCustomer.php index 9ad6713..c0de106 100644 --- a/lib/models/CreateCustomer.php +++ b/lib/models/CreateCustomer.php @@ -99,27 +99,27 @@ class CreateCustomer implements ArrayAccess { public $correlation_id; /* string */ public function __construct(array $data = null) { - $this->first_name = $data["first_name"]; - $this->last_name = $data["last_name"]; - $this->email = $data["email"]; - $this->ip_address = $data["ip_address"]; - $this->type = $data["type"]; - $this->address1 = $data["address1"]; - $this->address2 = $data["address2"]; - $this->city = $data["city"]; - $this->state = $data["state"]; - $this->postal_code = $data["postal_code"]; - $this->date_of_birth = $data["date_of_birth"]; - $this->ssn = $data["ssn"]; - $this->phone = $data["phone"]; - $this->business_name = $data["business_name"]; - $this->business_type = $data["business_type"]; - $this->business_classification = $data["business_classification"]; - $this->ein = $data["ein"]; - $this->doing_business_as = $data["doing_business_as"]; - $this->website = $data["website"]; - $this->controller = $data["controller"]; - $this->correlation_id = $data["correlation_id"]; + $this->first_name = $data["first_name"] ?? null; + $this->last_name = $data["last_name"] ?? null; + $this->email = $data["email"] ?? null; + $this->ip_address = $data["ip_address"] ?? null; + $this->type = $data["type"] ?? null; + $this->address1 = $data["address1"] ?? null; + $this->address2 = $data["address2"] ?? null; + $this->city = $data["city"] ?? null; + $this->state = $data["state"] ?? null; + $this->postal_code = $data["postal_code"] ?? null; + $this->date_of_birth = $data["date_of_birth"] ?? null; + $this->ssn = $data["ssn"] ?? null; + $this->phone = $data["phone"] ?? null; + $this->business_name = $data["business_name"] ?? null; + $this->business_type = $data["business_type"] ?? null; + $this->business_classification = $data["business_classification"] ?? null; + $this->ein = $data["ein"] ?? null; + $this->doing_business_as = $data["doing_business_as"] ?? null; + $this->website = $data["website"] ?? null; + $this->controller = $data["controller"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CreateCustomerLabelRequest.php b/lib/models/CreateCustomerLabelRequest.php index f25a71d..7a373eb 100644 --- a/lib/models/CreateCustomerLabelRequest.php +++ b/lib/models/CreateCustomerLabelRequest.php @@ -39,7 +39,7 @@ class CreateCustomerLabelRequest implements ArrayAccess { public $amount; /* Amount */ public function __construct(array $data = null) { - $this->amount = $data["amount"]; + $this->amount = $data["amount"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CreateFundingSourceRequest.php b/lib/models/CreateFundingSourceRequest.php index 600356f..3d0131c 100644 --- a/lib/models/CreateFundingSourceRequest.php +++ b/lib/models/CreateFundingSourceRequest.php @@ -60,14 +60,14 @@ class CreateFundingSourceRequest implements ArrayAccess { public $channels; /* array[string] */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->routing_number = $data["routing_number"]; - $this->account_number = $data["account_number"]; - $this->type = $data["type"]; - $this->bank_account_type = $data["bank_account_type"]; - $this->name = $data["name"]; - $this->verified = $data["verified"]; - $this->channels = $data["channels"]; + $this->_links = $data["_links"] ?? null; + $this->routing_number = $data["routing_number"] ?? null; + $this->account_number = $data["account_number"] ?? null; + $this->type = $data["type"] ?? null; + $this->bank_account_type = $data["bank_account_type"] ?? null; + $this->name = $data["name"] ?? null; + $this->verified = $data["verified"] ?? null; + $this->channels = $data["channels"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CreateOwnerRequest.php b/lib/models/CreateOwnerRequest.php index ecc8607..47832de 100644 --- a/lib/models/CreateOwnerRequest.php +++ b/lib/models/CreateOwnerRequest.php @@ -54,12 +54,12 @@ class CreateOwnerRequest implements ArrayAccess { public $passport; /* Passport */ public function __construct(array $data = null) { - $this->first_name = $data["first_name"]; - $this->last_name = $data["last_name"]; - $this->ssn = $data["ssn"]; - $this->date_of_birth = $data["date_of_birth"]; - $this->address = $data["address"]; - $this->passport = $data["passport"]; + $this->first_name = $data["first_name"] ?? null; + $this->last_name = $data["last_name"] ?? null; + $this->ssn = $data["ssn"] ?? null; + $this->date_of_birth = $data["date_of_birth"] ?? null; + $this->address = $data["address"] ?? null; + $this->passport = $data["passport"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CreateWebhook.php b/lib/models/CreateWebhook.php index 6e58ac8..70b7377 100644 --- a/lib/models/CreateWebhook.php +++ b/lib/models/CreateWebhook.php @@ -42,8 +42,8 @@ class CreateWebhook implements ArrayAccess { public $secret; /* string */ public function __construct(array $data = null) { - $this->url = $data["url"]; - $this->secret = $data["secret"]; + $this->url = $data["url"] ?? null; + $this->secret = $data["secret"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Customer.php b/lib/models/Customer.php index bace8fa..a912975 100644 --- a/lib/models/Customer.php +++ b/lib/models/Customer.php @@ -96,26 +96,26 @@ class Customer implements ArrayAccess { public $correlation_id; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->first_name = $data["first_name"]; - $this->last_name = $data["last_name"]; - $this->email = $data["email"]; - $this->type = $data["type"]; - $this->status = $data["status"]; - $this->created = $data["created"]; - $this->address1 = $data["address1"]; - $this->address2 = $data["address2"]; - $this->city = $data["city"]; - $this->state = $data["state"]; - $this->postal_code = $data["postal_code"]; - $this->phone = $data["phone"]; - $this->business_name = $data["business_name"]; - $this->doing_business_as = $data["doing_business_as"]; - $this->website = $data["website"]; - $this->controller = $data["controller"]; - $this->correlation_id = $data["correlation_id"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->first_name = $data["first_name"] ?? null; + $this->last_name = $data["last_name"] ?? null; + $this->email = $data["email"] ?? null; + $this->type = $data["type"] ?? null; + $this->status = $data["status"] ?? null; + $this->created = $data["created"] ?? null; + $this->address1 = $data["address1"] ?? null; + $this->address2 = $data["address2"] ?? null; + $this->city = $data["city"] ?? null; + $this->state = $data["state"] ?? null; + $this->postal_code = $data["postal_code"] ?? null; + $this->phone = $data["phone"] ?? null; + $this->business_name = $data["business_name"] ?? null; + $this->doing_business_as = $data["doing_business_as"] ?? null; + $this->website = $data["website"] ?? null; + $this->controller = $data["controller"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CustomerListResponse.php b/lib/models/CustomerListResponse.php index 377e889..f14d6f7 100644 --- a/lib/models/CustomerListResponse.php +++ b/lib/models/CustomerListResponse.php @@ -45,9 +45,9 @@ class CustomerListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/CustomerOAuthToken.php b/lib/models/CustomerOAuthToken.php index 81a83aa..8d3dbc1 100644 --- a/lib/models/CustomerOAuthToken.php +++ b/lib/models/CustomerOAuthToken.php @@ -45,9 +45,9 @@ class CustomerOAuthToken implements ArrayAccess { public $token; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->token = $data["token"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->token = $data["token"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Document.php b/lib/models/Document.php index f8f17ae..9a831f6 100644 --- a/lib/models/Document.php +++ b/lib/models/Document.php @@ -60,13 +60,13 @@ class Document implements ArrayAccess { public $_embedded; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->id = $data["id"]; - $this->status = $data["status"]; - $this->type = $data["type"]; - $this->created = $data["created"]; - $this->failure_reason = $data["failure_reason"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->id = $data["id"] ?? null; + $this->status = $data["status"] ?? null; + $this->type = $data["type"] ?? null; + $this->created = $data["created"] ?? null; + $this->failure_reason = $data["failure_reason"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/DocumentListResponse.php b/lib/models/DocumentListResponse.php index 2d18863..bee647e 100644 --- a/lib/models/DocumentListResponse.php +++ b/lib/models/DocumentListResponse.php @@ -45,9 +45,9 @@ class DocumentListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/EventListResponse.php b/lib/models/EventListResponse.php index d450142..249c061 100644 --- a/lib/models/EventListResponse.php +++ b/lib/models/EventListResponse.php @@ -45,9 +45,9 @@ class EventListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/FacilitatorFeeRequest.php b/lib/models/FacilitatorFeeRequest.php index 6121928..1df2a6f 100644 --- a/lib/models/FacilitatorFeeRequest.php +++ b/lib/models/FacilitatorFeeRequest.php @@ -42,8 +42,8 @@ class FacilitatorFeeRequest implements ArrayAccess { public $amount; /* Amount */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->amount = $data["amount"]; + $this->_links = $data["_links"] ?? null; + $this->amount = $data["amount"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/FailureDetails.php b/lib/models/FailureDetails.php index ec55d5e..a1a2b3f 100644 --- a/lib/models/FailureDetails.php +++ b/lib/models/FailureDetails.php @@ -42,8 +42,8 @@ class FailureDetails implements ArrayAccess { public $description; /* string */ public function __construct(array $data = null) { - $this->code = $data["code"]; - $this->description = $data["description"]; + $this->code = $data["code"] ?? null; + $this->description = $data["description"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/FeesBySourceResponse.php b/lib/models/FeesBySourceResponse.php index db34fc3..3d0f456 100644 --- a/lib/models/FeesBySourceResponse.php +++ b/lib/models/FeesBySourceResponse.php @@ -48,10 +48,10 @@ class FeesBySourceResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->transactions = $data["transactions"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->transactions = $data["transactions"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/FullAccountInfo.php b/lib/models/FullAccountInfo.php index f4d8f66..efca942 100644 --- a/lib/models/FullAccountInfo.php +++ b/lib/models/FullAccountInfo.php @@ -54,12 +54,12 @@ class FullAccountInfo implements ArrayAccess { public $_embedded; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->id = $data["id"]; - $this->name = $data["name"]; - $this->timezone_offset = $data["timezone_offset"]; - $this->type = $data["type"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->id = $data["id"] ?? null; + $this->name = $data["name"] ?? null; + $this->timezone_offset = $data["timezone_offset"] ?? null; + $this->type = $data["type"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/FundingSource.php b/lib/models/FundingSource.php index acecf28..e0e3238 100644 --- a/lib/models/FundingSource.php +++ b/lib/models/FundingSource.php @@ -78,20 +78,20 @@ class FundingSource implements ArrayAccess { public $fingerprint; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->status = $data["status"]; - $this->type = $data["type"]; - $this->bank_account_type = $data["bank_account_type"]; - $this->name = $data["name"]; - $this->created = $data["created"]; - $this->balance = $data["balance"]; - $this->removed = $data["removed"]; - $this->channels = $data["channels"]; - $this->bank_name = $data["bank_name"]; - $this->iav_account_holders = $data["iav_account_holders"]; - $this->fingerprint = $data["fingerprint"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->status = $data["status"] ?? null; + $this->type = $data["type"] ?? null; + $this->bank_account_type = $data["bank_account_type"] ?? null; + $this->name = $data["name"] ?? null; + $this->created = $data["created"] ?? null; + $this->balance = $data["balance"] ?? null; + $this->removed = $data["removed"] ?? null; + $this->channels = $data["channels"] ?? null; + $this->bank_name = $data["bank_name"] ?? null; + $this->iav_account_holders = $data["iav_account_holders"] ?? null; + $this->fingerprint = $data["fingerprint"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/FundingSourceBalance.php b/lib/models/FundingSourceBalance.php index cf53ffc..ea04277 100644 --- a/lib/models/FundingSourceBalance.php +++ b/lib/models/FundingSourceBalance.php @@ -51,11 +51,11 @@ class FundingSourceBalance implements ArrayAccess { public $status; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->balance = $data["balance"]; - $this->last_updated = $data["last_updated"]; - $this->status = $data["status"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->balance = $data["balance"] ?? null; + $this->last_updated = $data["last_updated"] ?? null; + $this->status = $data["status"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/FundingSourceListResponse.php b/lib/models/FundingSourceListResponse.php index cc12367..692ea8e 100644 --- a/lib/models/FundingSourceListResponse.php +++ b/lib/models/FundingSourceListResponse.php @@ -42,8 +42,8 @@ class FundingSourceListResponse implements ArrayAccess { public $_embedded; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/HalLink.php b/lib/models/HalLink.php index 8fd94d0..6c41499 100644 --- a/lib/models/HalLink.php +++ b/lib/models/HalLink.php @@ -45,9 +45,9 @@ class HalLink implements ArrayAccess { public $resource_type; /* string */ public function __construct(array $data = null) { - $this->href = $data["href"]; - $this->type = $data["type"]; - $this->resource_type = $data["resource_type"]; + $this->href = $data["href"] ?? null; + $this->type = $data["type"] ?? null; + $this->resource_type = $data["resource_type"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/IavToken.php b/lib/models/IavToken.php index ca45786..94d1c8c 100644 --- a/lib/models/IavToken.php +++ b/lib/models/IavToken.php @@ -45,9 +45,9 @@ class IavToken implements ArrayAccess { public $token; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->token = $data["token"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->token = $data["token"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/KbaAnswer.php b/lib/models/KbaAnswer.php index 487e0f4..d061372 100644 --- a/lib/models/KbaAnswer.php +++ b/lib/models/KbaAnswer.php @@ -42,8 +42,8 @@ class KbaAnswer implements ArrayAccess { public $text; /* string */ public function __construct(array $data = null) { - $this->id = $data["id"]; - $this->text = $data["text"]; + $this->id = $data["id"] ?? null; + $this->text = $data["text"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/KbaQuestion.php b/lib/models/KbaQuestion.php index 673d0e9..2d91104 100644 --- a/lib/models/KbaQuestion.php +++ b/lib/models/KbaQuestion.php @@ -45,9 +45,9 @@ class KbaQuestion implements ArrayAccess { public $answers; /* array[Answer] */ public function __construct(array $data = null) { - $this->id = $data["id"]; - $this->text = $data["text"]; - $this->answers = $data["answers"]; + $this->id = $data["id"] ?? null; + $this->text = $data["text"] ?? null; + $this->answers = $data["answers"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/KbaQuestions.php b/lib/models/KbaQuestions.php index fa93913..3dcc153 100644 --- a/lib/models/KbaQuestions.php +++ b/lib/models/KbaQuestions.php @@ -48,10 +48,10 @@ class KbaQuestions implements ArrayAccess { public $_embedded; /* map[string,Number] */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->id = $data["id"]; - $this->questions = $data["questions"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->id = $data["id"] ?? null; + $this->questions = $data["questions"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Label.php b/lib/models/Label.php index 91d7860..b4c337c 100644 --- a/lib/models/Label.php +++ b/lib/models/Label.php @@ -51,11 +51,11 @@ class Label implements ArrayAccess { public $amount; /* Amount */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->created = $data["created"]; - $this->amount = $data["amount"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->created = $data["created"] ?? null; + $this->amount = $data["amount"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/LabelListResponse.php b/lib/models/LabelListResponse.php index 6f0005b..ca6234f 100644 --- a/lib/models/LabelListResponse.php +++ b/lib/models/LabelListResponse.php @@ -45,9 +45,9 @@ class LabelListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/LabelReallocation.php b/lib/models/LabelReallocation.php index 0eeae9b..a088330 100644 --- a/lib/models/LabelReallocation.php +++ b/lib/models/LabelReallocation.php @@ -45,9 +45,9 @@ class LabelReallocation implements ArrayAccess { public $created; /* DateTime */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->created = $data["created"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->created = $data["created"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/LabelReallocationRequest.php b/lib/models/LabelReallocationRequest.php index 6d57e09..b2fb4f6 100644 --- a/lib/models/LabelReallocationRequest.php +++ b/lib/models/LabelReallocationRequest.php @@ -42,8 +42,8 @@ class LabelReallocationRequest implements ArrayAccess { public $amount; /* Amount */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->amount = $data["amount"]; + $this->_links = $data["_links"] ?? null; + $this->amount = $data["amount"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/LedgerEntry.php b/lib/models/LedgerEntry.php index 2bb27ba..5a51056 100644 --- a/lib/models/LedgerEntry.php +++ b/lib/models/LedgerEntry.php @@ -51,11 +51,11 @@ class LedgerEntry implements ArrayAccess { public $created; /* DateTime */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->amount = $data["amount"]; - $this->created = $data["created"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->amount = $data["amount"] ?? null; + $this->created = $data["created"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/LedgerEntryListResponse.php b/lib/models/LedgerEntryListResponse.php index 2ec94c8..19ca533 100644 --- a/lib/models/LedgerEntryListResponse.php +++ b/lib/models/LedgerEntryListResponse.php @@ -45,9 +45,9 @@ class LedgerEntryListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MassPayment.php b/lib/models/MassPayment.php index c1d69fa..81b18e1 100644 --- a/lib/models/MassPayment.php +++ b/lib/models/MassPayment.php @@ -63,15 +63,15 @@ class MassPayment implements ArrayAccess { public $correlation_id; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->status = $data["status"]; - $this->created = $data["created"]; - $this->metadata = $data["metadata"]; - $this->total = $data["total"]; - $this->total_fees = $data["total_fees"]; - $this->correlation_id = $data["correlation_id"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->status = $data["status"] ?? null; + $this->created = $data["created"] ?? null; + $this->metadata = $data["metadata"] ?? null; + $this->total = $data["total"] ?? null; + $this->total_fees = $data["total_fees"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MassPaymentItem.php b/lib/models/MassPaymentItem.php index 5b178a4..9e690be 100644 --- a/lib/models/MassPaymentItem.php +++ b/lib/models/MassPaymentItem.php @@ -57,13 +57,13 @@ class MassPaymentItem implements ArrayAccess { public $correlation_id; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->status = $data["status"]; - $this->amount = $data["amount"]; - $this->metadata = $data["metadata"]; - $this->correlation_id = $data["correlation_id"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->status = $data["status"] ?? null; + $this->amount = $data["amount"] ?? null; + $this->metadata = $data["metadata"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MassPaymentItemListResponse.php b/lib/models/MassPaymentItemListResponse.php index 355d97a..d5bf464 100644 --- a/lib/models/MassPaymentItemListResponse.php +++ b/lib/models/MassPaymentItemListResponse.php @@ -45,9 +45,9 @@ class MassPaymentItemListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MassPaymentItemRequestBody.php b/lib/models/MassPaymentItemRequestBody.php index a4b8e78..d15752a 100644 --- a/lib/models/MassPaymentItemRequestBody.php +++ b/lib/models/MassPaymentItemRequestBody.php @@ -51,11 +51,11 @@ class MassPaymentItemRequestBody implements ArrayAccess { public $ach_details; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->amount = $data["amount"]; - $this->metadata = $data["metadata"]; - $this->correlation_id = $data["correlation_id"]; - $this->ach_details = $data["ach_details"]; + $this->_links = $data["_links"] ?? null; + $this->amount = $data["amount"] ?? null; + $this->metadata = $data["metadata"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; + $this->ach_details = $data["ach_details"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MassPaymentListResponse.php b/lib/models/MassPaymentListResponse.php index 8afc676..39d70b0 100644 --- a/lib/models/MassPaymentListResponse.php +++ b/lib/models/MassPaymentListResponse.php @@ -45,9 +45,9 @@ class MassPaymentListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MassPaymentRequestBody.php b/lib/models/MassPaymentRequestBody.php index aea8082..7ae17a9 100644 --- a/lib/models/MassPaymentRequestBody.php +++ b/lib/models/MassPaymentRequestBody.php @@ -54,12 +54,12 @@ class MassPaymentRequestBody implements ArrayAccess { public $ach_details; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->items = $data["items"]; - $this->metadata = $data["metadata"]; - $this->status = $data["status"]; - $this->correlation_id = $data["correlation_id"]; - $this->ach_details = $data["ach_details"]; + $this->_links = $data["_links"] ?? null; + $this->items = $data["items"] ?? null; + $this->metadata = $data["metadata"] ?? null; + $this->status = $data["status"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; + $this->ach_details = $data["ach_details"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MicroDeposits.php b/lib/models/MicroDeposits.php index 6fabe97..d4b5f0d 100644 --- a/lib/models/MicroDeposits.php +++ b/lib/models/MicroDeposits.php @@ -42,8 +42,8 @@ class MicroDeposits implements ArrayAccess { public $_embedded; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/MicroDepositsInitiated.php b/lib/models/MicroDepositsInitiated.php index 2fcefcc..dff1d8b 100644 --- a/lib/models/MicroDepositsInitiated.php +++ b/lib/models/MicroDepositsInitiated.php @@ -51,11 +51,11 @@ class MicroDepositsInitiated implements ArrayAccess { public $failure; /* FailureDetails */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->created = $data["created"]; - $this->status = $data["status"]; - $this->failure = $data["failure"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->created = $data["created"] ?? null; + $this->status = $data["status"] ?? null; + $this->failure = $data["failure"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Money.php b/lib/models/Money.php index 687e9b0..cdfed5c 100644 --- a/lib/models/Money.php +++ b/lib/models/Money.php @@ -42,8 +42,8 @@ class Money implements ArrayAccess { public $currency; /* string */ public function __construct(array $data = null) { - $this->value = $data["value"]; - $this->currency = $data["currency"]; + $this->value = $data["value"] ?? null; + $this->currency = $data["currency"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/OAuthResponse.php b/lib/models/OAuthResponse.php index 294fbd1..5c8019b 100644 --- a/lib/models/OAuthResponse.php +++ b/lib/models/OAuthResponse.php @@ -57,13 +57,13 @@ class OAuthResponse implements ArrayAccess { public $scope; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->access_token = $data["access_token"]; - $this->expires_in = $data["expires_in"]; - $this->refresh_token = $data["refresh_token"]; - $this->refresh_expires_in = $data["refresh_expires_in"]; - $this->token_type = $data["token_type"]; - $this->scope = $data["scope"]; + $this->_links = $data["_links"] ?? null; + $this->access_token = $data["access_token"] ?? null; + $this->expires_in = $data["expires_in"] ?? null; + $this->refresh_token = $data["refresh_token"] ?? null; + $this->refresh_expires_in = $data["refresh_expires_in"] ?? null; + $this->token_type = $data["token_type"] ?? null; + $this->scope = $data["scope"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Owner.php b/lib/models/Owner.php index 947657d..2d4e88e 100644 --- a/lib/models/Owner.php +++ b/lib/models/Owner.php @@ -60,14 +60,14 @@ class Owner implements ArrayAccess { public $created; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->id = $data["id"]; - $this->first_name = $data["first_name"]; - $this->last_name = $data["last_name"]; - $this->address = $data["address"]; - $this->verification_status = $data["verification_status"]; - $this->_embedded = $data["_embedded"]; - $this->created = $data["created"]; + $this->_links = $data["_links"] ?? null; + $this->id = $data["id"] ?? null; + $this->first_name = $data["first_name"] ?? null; + $this->last_name = $data["last_name"] ?? null; + $this->address = $data["address"] ?? null; + $this->verification_status = $data["verification_status"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->created = $data["created"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Ownership.php b/lib/models/Ownership.php index 90c9bba..aa304e1 100644 --- a/lib/models/Ownership.php +++ b/lib/models/Ownership.php @@ -45,9 +45,9 @@ class Ownership implements ArrayAccess { public $_embedded; /* map[string,Number] */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->status = $data["status"]; - $this->_embedded = $data["_embedded"]; + $this->_links = $data["_links"] ?? null; + $this->status = $data["status"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Passport.php b/lib/models/Passport.php index 0838e29..6f455b4 100644 --- a/lib/models/Passport.php +++ b/lib/models/Passport.php @@ -42,8 +42,8 @@ class Passport implements ArrayAccess { public $country; /* string */ public function __construct(array $data = null) { - $this->number = $data["number"]; - $this->country = $data["country"]; + $this->number = $data["number"] ?? null; + $this->country = $data["country"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/ProcessResult.php b/lib/models/ProcessResult.php index f640395..28b9f9d 100644 --- a/lib/models/ProcessResult.php +++ b/lib/models/ProcessResult.php @@ -45,9 +45,9 @@ class ProcessResult implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/RemoveBankRequest.php b/lib/models/RemoveBankRequest.php index 56f86fc..f123308 100644 --- a/lib/models/RemoveBankRequest.php +++ b/lib/models/RemoveBankRequest.php @@ -39,7 +39,7 @@ class RemoveBankRequest implements ArrayAccess { public $removed; /* boolean */ public function __construct(array $data = null) { - $this->removed = $data["removed"]; + $this->removed = $data["removed"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Transfer.php b/lib/models/Transfer.php index d202e96..8e45a9d 100644 --- a/lib/models/Transfer.php +++ b/lib/models/Transfer.php @@ -69,17 +69,17 @@ class Transfer implements ArrayAccess { public $ach_details; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->status = $data["status"]; - $this->amount = $data["amount"]; - $this->created = $data["created"]; - $this->metadata = $data["metadata"]; - $this->clearing = $data["clearing"]; - $this->correlation_id = $data["correlation_id"]; - $this->individual_ach_id = $data["individual_ach_id"]; - $this->ach_details = $data["ach_details"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->status = $data["status"] ?? null; + $this->amount = $data["amount"] ?? null; + $this->created = $data["created"] ?? null; + $this->metadata = $data["metadata"] ?? null; + $this->clearing = $data["clearing"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; + $this->individual_ach_id = $data["individual_ach_id"] ?? null; + $this->ach_details = $data["ach_details"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/TransferFailure.php b/lib/models/TransferFailure.php index 8920ba3..12c0354 100644 --- a/lib/models/TransferFailure.php +++ b/lib/models/TransferFailure.php @@ -54,12 +54,12 @@ class TransferFailure implements ArrayAccess { public $created; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->code = $data["code"]; - $this->description = $data["description"]; - $this->explanation = $data["explanation"]; - $this->created = $data["created"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->code = $data["code"] ?? null; + $this->description = $data["description"] ?? null; + $this->explanation = $data["explanation"] ?? null; + $this->created = $data["created"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/TransferListResponse.php b/lib/models/TransferListResponse.php index d8de1d4..54f58f1 100644 --- a/lib/models/TransferListResponse.php +++ b/lib/models/TransferListResponse.php @@ -45,9 +45,9 @@ class TransferListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/TransferRequestBody.php b/lib/models/TransferRequestBody.php index 9b2af17..81ce890 100644 --- a/lib/models/TransferRequestBody.php +++ b/lib/models/TransferRequestBody.php @@ -60,14 +60,14 @@ class TransferRequestBody implements ArrayAccess { public $ach_details; /* object */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->amount = $data["amount"]; - $this->metadata = $data["metadata"]; - $this->fees = $data["fees"]; - $this->clearing = $data["clearing"]; - $this->imad = $data["imad"]; - $this->correlation_id = $data["correlation_id"]; - $this->ach_details = $data["ach_details"]; + $this->_links = $data["_links"] ?? null; + $this->amount = $data["amount"] ?? null; + $this->metadata = $data["metadata"] ?? null; + $this->fees = $data["fees"] ?? null; + $this->clearing = $data["clearing"] ?? null; + $this->imad = $data["imad"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; + $this->ach_details = $data["ach_details"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/UpdateBankRequest.php b/lib/models/UpdateBankRequest.php index baafb78..371bdd4 100644 --- a/lib/models/UpdateBankRequest.php +++ b/lib/models/UpdateBankRequest.php @@ -51,11 +51,11 @@ class UpdateBankRequest implements ArrayAccess { public $bank_account_type; /* string */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->name = $data["name"]; - $this->routing_number = $data["routing_number"]; - $this->account_number = $data["account_number"]; - $this->bank_account_type = $data["bank_account_type"]; + $this->_links = $data["_links"] ?? null; + $this->name = $data["name"] ?? null; + $this->routing_number = $data["routing_number"] ?? null; + $this->account_number = $data["account_number"] ?? null; + $this->bank_account_type = $data["bank_account_type"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/UpdateCustomer.php b/lib/models/UpdateCustomer.php index 4dec928..b7d095f 100644 --- a/lib/models/UpdateCustomer.php +++ b/lib/models/UpdateCustomer.php @@ -102,28 +102,28 @@ class UpdateCustomer implements ArrayAccess { public $correlation_id; /* string */ public function __construct(array $data = null) { - $this->first_name = $data["first_name"]; - $this->last_name = $data["last_name"]; - $this->email = $data["email"]; - $this->ip_address = $data["ip_address"]; - $this->type = $data["type"]; - $this->status = $data["status"]; - $this->address1 = $data["address1"]; - $this->address2 = $data["address2"]; - $this->city = $data["city"]; - $this->state = $data["state"]; - $this->postal_code = $data["postal_code"]; - $this->date_of_birth = $data["date_of_birth"]; - $this->ssn = $data["ssn"]; - $this->phone = $data["phone"]; - $this->business_name = $data["business_name"]; - $this->business_type = $data["business_type"]; - $this->business_classification = $data["business_classification"]; - $this->ein = $data["ein"]; - $this->doing_business_as = $data["doing_business_as"]; - $this->website = $data["website"]; - $this->controller = $data["controller"]; - $this->correlation_id = $data["correlation_id"]; + $this->first_name = $data["first_name"] ?? null; + $this->last_name = $data["last_name"] ?? null; + $this->email = $data["email"] ?? null; + $this->ip_address = $data["ip_address"] ?? null; + $this->type = $data["type"] ?? null; + $this->status = $data["status"] ?? null; + $this->address1 = $data["address1"] ?? null; + $this->address2 = $data["address2"] ?? null; + $this->city = $data["city"] ?? null; + $this->state = $data["state"] ?? null; + $this->postal_code = $data["postal_code"] ?? null; + $this->date_of_birth = $data["date_of_birth"] ?? null; + $this->ssn = $data["ssn"] ?? null; + $this->phone = $data["phone"] ?? null; + $this->business_name = $data["business_name"] ?? null; + $this->business_type = $data["business_type"] ?? null; + $this->business_classification = $data["business_classification"] ?? null; + $this->ein = $data["ein"] ?? null; + $this->doing_business_as = $data["doing_business_as"] ?? null; + $this->website = $data["website"] ?? null; + $this->controller = $data["controller"] ?? null; + $this->correlation_id = $data["correlation_id"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/UpdateJobRequestBody.php b/lib/models/UpdateJobRequestBody.php index 93eb493..0ca7f1a 100644 --- a/lib/models/UpdateJobRequestBody.php +++ b/lib/models/UpdateJobRequestBody.php @@ -39,7 +39,7 @@ class UpdateJobRequestBody implements ArrayAccess { public $status; /* string */ public function __construct(array $data = null) { - $this->status = $data["status"]; + $this->status = $data["status"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/UpdateOwnerRequest.php b/lib/models/UpdateOwnerRequest.php index e4631e4..cb6672f 100644 --- a/lib/models/UpdateOwnerRequest.php +++ b/lib/models/UpdateOwnerRequest.php @@ -54,12 +54,12 @@ class UpdateOwnerRequest implements ArrayAccess { public $passport; /* Passport */ public function __construct(array $data = null) { - $this->first_name = $data["first_name"]; - $this->last_name = $data["last_name"]; - $this->ssn = $data["ssn"]; - $this->date_of_birth = $data["date_of_birth"]; - $this->address = $data["address"]; - $this->passport = $data["passport"]; + $this->first_name = $data["first_name"] ?? null; + $this->last_name = $data["last_name"] ?? null; + $this->ssn = $data["ssn"] ?? null; + $this->date_of_birth = $data["date_of_birth"] ?? null; + $this->address = $data["address"] ?? null; + $this->passport = $data["passport"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/UpdateSubscription.php b/lib/models/UpdateSubscription.php index 4cbf8a1..719127c 100644 --- a/lib/models/UpdateSubscription.php +++ b/lib/models/UpdateSubscription.php @@ -39,7 +39,7 @@ class UpdateSubscription implements ArrayAccess { public $paused; /* boolean */ public function __construct(array $data = null) { - $this->paused = $data["paused"]; + $this->paused = $data["paused"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/UpdateTransfer.php b/lib/models/UpdateTransfer.php index b708d1b..ff417fd 100644 --- a/lib/models/UpdateTransfer.php +++ b/lib/models/UpdateTransfer.php @@ -39,7 +39,7 @@ class UpdateTransfer implements ArrayAccess { public $status; /* string */ public function __construct(array $data = null) { - $this->status = $data["status"]; + $this->status = $data["status"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/VerifyMicroDepositsRequest.php b/lib/models/VerifyMicroDepositsRequest.php index 3339deb..2c6749b 100644 --- a/lib/models/VerifyMicroDepositsRequest.php +++ b/lib/models/VerifyMicroDepositsRequest.php @@ -42,8 +42,8 @@ class VerifyMicroDepositsRequest implements ArrayAccess { public $amount2; /* Amount */ public function __construct(array $data = null) { - $this->amount1 = $data["amount1"]; - $this->amount2 = $data["amount2"]; + $this->amount1 = $data["amount1"] ?? null; + $this->amount2 = $data["amount2"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/Webhook.php b/lib/models/Webhook.php index e7fe93c..4525458 100644 --- a/lib/models/Webhook.php +++ b/lib/models/Webhook.php @@ -60,14 +60,14 @@ class Webhook implements ArrayAccess { public $attempts; /* array[WebhookAttempt] */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->topic = $data["topic"]; - $this->account_id = $data["account_id"]; - $this->event_id = $data["event_id"]; - $this->subscription_id = $data["subscription_id"]; - $this->attempts = $data["attempts"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->topic = $data["topic"] ?? null; + $this->account_id = $data["account_id"] ?? null; + $this->event_id = $data["event_id"] ?? null; + $this->subscription_id = $data["subscription_id"] ?? null; + $this->attempts = $data["attempts"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookAttempt.php b/lib/models/WebhookAttempt.php index 5042fb4..8971e57 100644 --- a/lib/models/WebhookAttempt.php +++ b/lib/models/WebhookAttempt.php @@ -45,9 +45,9 @@ class WebhookAttempt implements ArrayAccess { public $response; /* WebhookHttpResponse */ public function __construct(array $data = null) { - $this->id = $data["id"]; - $this->request = $data["request"]; - $this->response = $data["response"]; + $this->id = $data["id"] ?? null; + $this->request = $data["request"] ?? null; + $this->response = $data["response"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookEventListResponse.php b/lib/models/WebhookEventListResponse.php index 5ef8b48..f3fe175 100644 --- a/lib/models/WebhookEventListResponse.php +++ b/lib/models/WebhookEventListResponse.php @@ -45,9 +45,9 @@ class WebhookEventListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookHeader.php b/lib/models/WebhookHeader.php index 65e363d..2015530 100644 --- a/lib/models/WebhookHeader.php +++ b/lib/models/WebhookHeader.php @@ -42,8 +42,8 @@ class WebhookHeader implements ArrayAccess { public $value; /* string */ public function __construct(array $data = null) { - $this->name = $data["name"]; - $this->value = $data["value"]; + $this->name = $data["name"] ?? null; + $this->value = $data["value"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookHttpRequest.php b/lib/models/WebhookHttpRequest.php index ac6a369..9ed30ec 100644 --- a/lib/models/WebhookHttpRequest.php +++ b/lib/models/WebhookHttpRequest.php @@ -48,10 +48,10 @@ class WebhookHttpRequest implements ArrayAccess { public $body; /* string */ public function __construct(array $data = null) { - $this->timestamp = $data["timestamp"]; - $this->url = $data["url"]; - $this->headers = $data["headers"]; - $this->body = $data["body"]; + $this->timestamp = $data["timestamp"] ?? null; + $this->url = $data["url"] ?? null; + $this->headers = $data["headers"] ?? null; + $this->body = $data["body"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookHttpResponse.php b/lib/models/WebhookHttpResponse.php index 25748ae..be17a43 100644 --- a/lib/models/WebhookHttpResponse.php +++ b/lib/models/WebhookHttpResponse.php @@ -48,10 +48,10 @@ class WebhookHttpResponse implements ArrayAccess { public $body; /* string */ public function __construct(array $data = null) { - $this->timestamp = $data["timestamp"]; - $this->headers = $data["headers"]; - $this->status_code = $data["status_code"]; - $this->body = $data["body"]; + $this->timestamp = $data["timestamp"] ?? null; + $this->headers = $data["headers"] ?? null; + $this->status_code = $data["status_code"] ?? null; + $this->body = $data["body"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookListResponse.php b/lib/models/WebhookListResponse.php index c65a46a..618c01c 100644 --- a/lib/models/WebhookListResponse.php +++ b/lib/models/WebhookListResponse.php @@ -45,9 +45,9 @@ class WebhookListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookRetry.php b/lib/models/WebhookRetry.php index b2582f4..e109ec8 100644 --- a/lib/models/WebhookRetry.php +++ b/lib/models/WebhookRetry.php @@ -48,10 +48,10 @@ class WebhookRetry implements ArrayAccess { public $timestamp; /* DateTime */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->timestamp = $data["timestamp"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->timestamp = $data["timestamp"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookRetryRequestListResponse.php b/lib/models/WebhookRetryRequestListResponse.php index 69fb885..acd79b1 100644 --- a/lib/models/WebhookRetryRequestListResponse.php +++ b/lib/models/WebhookRetryRequestListResponse.php @@ -45,9 +45,9 @@ class WebhookRetryRequestListResponse implements ArrayAccess { public $total; /* int */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->total = $data["total"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->total = $data["total"] ?? null; } public function offsetExists($offset) { diff --git a/lib/models/WebhookSubscription.php b/lib/models/WebhookSubscription.php index b1a9dee..2d305d2 100644 --- a/lib/models/WebhookSubscription.php +++ b/lib/models/WebhookSubscription.php @@ -54,12 +54,12 @@ class WebhookSubscription implements ArrayAccess { public $created; /* DateTime */ public function __construct(array $data = null) { - $this->_links = $data["_links"]; - $this->_embedded = $data["_embedded"]; - $this->id = $data["id"]; - $this->url = $data["url"]; - $this->paused = $data["paused"]; - $this->created = $data["created"]; + $this->_links = $data["_links"] ?? null; + $this->_embedded = $data["_embedded"] ?? null; + $this->id = $data["id"] ?? null; + $this->url = $data["url"] ?? null; + $this->paused = $data["paused"] ?? null; + $this->created = $data["created"] ?? null; } public function offsetExists($offset) {