From d96da84e24bb46ecc51f0511ea52b2caab8aaf4b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Aug 2022 07:22:26 +0000 Subject: [PATCH 01/20] Bump aglipanci/laravel-pint-action from 0.1.0 to 1.0.0 Bumps [aglipanci/laravel-pint-action](https://github.com/aglipanci/laravel-pint-action) from 0.1.0 to 1.0.0. - [Release notes](https://github.com/aglipanci/laravel-pint-action/releases) - [Commits](https://github.com/aglipanci/laravel-pint-action/compare/0.1.0...1.0.0) --- updated-dependencies: - dependency-name: aglipanci/laravel-pint-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/fix-php-code-style-issues.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/fix-php-code-style-issues.yml b/.github/workflows/fix-php-code-style-issues.yml index 9a784a1..970633c 100644 --- a/.github/workflows/fix-php-code-style-issues.yml +++ b/.github/workflows/fix-php-code-style-issues.yml @@ -13,7 +13,7 @@ jobs: ref: ${{ github.head_ref }} - name: Fix PHP code style issues - uses: aglipanci/laravel-pint-action@0.1.0 + uses: aglipanci/laravel-pint-action@1.0.0 - name: Commit changes uses: stefanzweifel/git-auto-commit-action@v4 From 414d78e3e5022e68cf0bfd81c5fdef181d40c9cb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Oct 2022 07:53:32 +0000 Subject: [PATCH 02/20] Bump dependabot/fetch-metadata from 1.3.3 to 1.3.4 Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.3.3 to 1.3.4. - [Release notes](https://github.com/dependabot/fetch-metadata/releases) - [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.3.3...v1.3.4) --- updated-dependencies: - dependency-name: dependabot/fetch-metadata dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .github/workflows/dependabot-auto-merge.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dependabot-auto-merge.yml b/.github/workflows/dependabot-auto-merge.yml index 14da349..41099d3 100644 --- a/.github/workflows/dependabot-auto-merge.yml +++ b/.github/workflows/dependabot-auto-merge.yml @@ -13,7 +13,7 @@ jobs: - name: Dependabot metadata id: metadata - uses: dependabot/fetch-metadata@v1.3.3 + uses: dependabot/fetch-metadata@v1.3.4 with: github-token: "${{ secrets.GITHUB_TOKEN }}" From 3243bb5176b9405a0f7e324240034f48a512ace8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Nov 2022 07:04:23 +0000 Subject: [PATCH 03/20] Bump dependabot/fetch-metadata from 1.3.4 to 1.3.5 Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.3.4 to 1.3.5. - [Release notes](https://github.com/dependabot/fetch-metadata/releases) - [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.3.4...v1.3.5) --- updated-dependencies: - dependency-name: dependabot/fetch-metadata dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .github/workflows/dependabot-auto-merge.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dependabot-auto-merge.yml b/.github/workflows/dependabot-auto-merge.yml index 41099d3..e7e28b9 100644 --- a/.github/workflows/dependabot-auto-merge.yml +++ b/.github/workflows/dependabot-auto-merge.yml @@ -13,7 +13,7 @@ jobs: - name: Dependabot metadata id: metadata - uses: dependabot/fetch-metadata@v1.3.4 + uses: dependabot/fetch-metadata@v1.3.5 with: github-token: "${{ secrets.GITHUB_TOKEN }}" From aaed6f390c29eeb6f2bee088bf0a2d7a645bdf2c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 21 Nov 2022 07:24:00 +0000 Subject: [PATCH 04/20] build(deps): bump ramsey/composer-install from 1 to 2 Bumps [ramsey/composer-install](https://github.com/ramsey/composer-install) from 1 to 2. - [Release notes](https://github.com/ramsey/composer-install/releases) - [Commits](https://github.com/ramsey/composer-install/compare/v1...v2) --- updated-dependencies: - dependency-name: ramsey/composer-install dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/phpstan.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/phpstan.yml b/.github/workflows/phpstan.yml index 557d263..9d41c0c 100644 --- a/.github/workflows/phpstan.yml +++ b/.github/workflows/phpstan.yml @@ -20,7 +20,7 @@ jobs: coverage: none - name: Install composer dependencies - uses: ramsey/composer-install@v1 + uses: ramsey/composer-install@v2 - name: Run PHPStan run: ./vendor/bin/phpstan --error-format=github From ba7d65feaeae069f2bce9395420baa4abaa5b69a Mon Sep 17 00:00:00 2001 From: Serhii Tonkoshkurik Date: Thu, 8 Dec 2022 12:15:19 +0100 Subject: [PATCH 05/20] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index e4a2668..3fea44a 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,7 @@ } ], "require": { - "php": "^7.4", + "php": "^7.4|^8.0|^8.1", "spatie/laravel-package-tools": "^1.9.2", "illuminate/contracts": "^8.83.20", "guzzlehttp/guzzle": "^7.0.1", From d7072480e38759ff57ef273f4cf8cab19e12061a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 30 Jan 2023 07:06:23 +0000 Subject: [PATCH 06/20] build(deps): bump dependabot/fetch-metadata from 1.3.5 to 1.3.6 Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.3.5 to 1.3.6. - [Release notes](https://github.com/dependabot/fetch-metadata/releases) - [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.3.5...v1.3.6) --- updated-dependencies: - dependency-name: dependabot/fetch-metadata dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .github/workflows/dependabot-auto-merge.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dependabot-auto-merge.yml b/.github/workflows/dependabot-auto-merge.yml index e7e28b9..32f7754 100644 --- a/.github/workflows/dependabot-auto-merge.yml +++ b/.github/workflows/dependabot-auto-merge.yml @@ -13,7 +13,7 @@ jobs: - name: Dependabot metadata id: metadata - uses: dependabot/fetch-metadata@v1.3.5 + uses: dependabot/fetch-metadata@v1.3.6 with: github-token: "${{ secrets.GITHUB_TOKEN }}" From e722182acf3781c5e0857327452cee42ab416a77 Mon Sep 17 00:00:00 2001 From: Serhii Tonkoshkurik Date: Wed, 15 Mar 2023 14:57:34 +0100 Subject: [PATCH 07/20] Add PHP ^8 support --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index e4a2668..7ec6cef 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,7 @@ } ], "require": { - "php": "^7.4", + "php": "^7.4|^8.0", "spatie/laravel-package-tools": "^1.9.2", "illuminate/contracts": "^8.83.20", "guzzlehttp/guzzle": "^7.0.1", From c853ef04de5556fd6de397d8a4c3e5524db21103 Mon Sep 17 00:00:00 2001 From: Serhii Tonkoshkurik Date: Wed, 15 Mar 2023 15:28:20 +0100 Subject: [PATCH 08/20] upgrade packages to support newest php version --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index 7ec6cef..72a21fc 100644 --- a/composer.json +++ b/composer.json @@ -18,12 +18,12 @@ "require": { "php": "^7.4|^8.0", "spatie/laravel-package-tools": "^1.9.2", - "illuminate/contracts": "^8.83.20", + "illuminate/contracts": "^9.0|^10.0", "guzzlehttp/guzzle": "^7.0.1", "ext-soap": "*" }, "require-dev": { - "nunomaduro/collision": "^5.0", + "nunomaduro/collision": "^6.1", "pestphp/pest": "^1.21", "pestphp/pest-plugin-laravel": "^1.1", "phpstan/extension-installer": "^1.1", From 5a7571d40baa60842abd48b00f8bb3c264ece1f2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Apr 2023 08:00:02 +0000 Subject: [PATCH 09/20] build(deps): bump dependabot/fetch-metadata from 1.3.6 to 1.4.0 Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.3.6 to 1.4.0. - [Release notes](https://github.com/dependabot/fetch-metadata/releases) - [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.3.6...v1.4.0) --- updated-dependencies: - dependency-name: dependabot/fetch-metadata dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/dependabot-auto-merge.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dependabot-auto-merge.yml b/.github/workflows/dependabot-auto-merge.yml index 32f7754..8fc6538 100644 --- a/.github/workflows/dependabot-auto-merge.yml +++ b/.github/workflows/dependabot-auto-merge.yml @@ -13,7 +13,7 @@ jobs: - name: Dependabot metadata id: metadata - uses: dependabot/fetch-metadata@v1.3.6 + uses: dependabot/fetch-metadata@v1.4.0 with: github-token: "${{ secrets.GITHUB_TOKEN }}" From bcdd2981b3a9badbe670e45eab5ff3daa6c35399 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 May 2023 07:59:06 +0000 Subject: [PATCH 10/20] build(deps): bump dependabot/fetch-metadata from 1.4.0 to 1.5.1 Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.4.0 to 1.5.1. - [Release notes](https://github.com/dependabot/fetch-metadata/releases) - [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.4.0...v1.5.1) --- updated-dependencies: - dependency-name: dependabot/fetch-metadata dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/dependabot-auto-merge.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dependabot-auto-merge.yml b/.github/workflows/dependabot-auto-merge.yml index 8fc6538..4af8e6b 100644 --- a/.github/workflows/dependabot-auto-merge.yml +++ b/.github/workflows/dependabot-auto-merge.yml @@ -13,7 +13,7 @@ jobs: - name: Dependabot metadata id: metadata - uses: dependabot/fetch-metadata@v1.4.0 + uses: dependabot/fetch-metadata@v1.5.1 with: github-token: "${{ secrets.GITHUB_TOKEN }}" From 5763c3542d1c0dfb57ac1ae16a9a03bbb0a2e674 Mon Sep 17 00:00:00 2001 From: Dmitry Filatov Date: Tue, 20 Jun 2023 14:49:06 +0300 Subject: [PATCH 11/20] fix: remove broadcast --- src/Events/RequestEvent.php | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/Events/RequestEvent.php b/src/Events/RequestEvent.php index 9ea387f..2db916d 100644 --- a/src/Events/RequestEvent.php +++ b/src/Events/RequestEvent.php @@ -2,15 +2,12 @@ namespace Xelon\VmWareClient\Events; -use Illuminate\Broadcasting\InteractsWithSockets; -use Illuminate\Broadcasting\PrivateChannel; use Illuminate\Foundation\Events\Dispatchable; use Illuminate\Queue\SerializesModels; class RequestEvent { use Dispatchable; - use InteractsWithSockets; use SerializesModels; public string $requestBody; @@ -25,9 +22,4 @@ public function __construct($requestBody, $responseBody, $status) $this->responseBody = $responseBody; $this->status = $status ? 'Success' : 'Error'; } - - public function broadcastOn() - { - return new PrivateChannel('vmware-client'); - } } From 541be0484a1d85edf4c3ce4b1b7d68ed05d1240f Mon Sep 17 00:00:00 2001 From: Andrii Hazhur Date: Thu, 29 Jun 2023 14:40:47 +0300 Subject: [PATCH 12/20] fix: hide password from request logs --- src/Requests/SoapRequest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Requests/SoapRequest.php b/src/Requests/SoapRequest.php index 89964cb..8dc47fd 100644 --- a/src/Requests/SoapRequest.php +++ b/src/Requests/SoapRequest.php @@ -35,7 +35,7 @@ public function request(string $method, array $requestBody, bool $convertToSoap 'SOAP REQUEST SUCCESS:'. "\nSOAP method: ".$method. property_exists($this->soapClient, '__last_request') - ? "\nSOAP request start***".$this->soapClient->__last_request.'***SOAP request end' + ? "\nSOAP request start***".preg_replace("#.+#", '*****', $this->soapClient->__last_request).'***SOAP request end' : '' ); } @@ -74,7 +74,7 @@ public function request(string $method, array $requestBody, bool $convertToSoap "\nSOAP method: ".$method. ( property_exists($this->soapClient, '__last_request') - ? "\nSOAP request start***".$this->soapClient->__last_request.'***SOAP request end' + ? "\nSOAP request start***".preg_replace("#.+#", '*****', $this->soapClient->__last_request).'***SOAP request end' : '' ).( property_exists($this->soapClient, '__last_response') From 76a181e2466f2a52cbe8b68143d725808b13fb0f Mon Sep 17 00:00:00 2001 From: gazhur94 Date: Thu, 29 Jun 2023 11:41:22 +0000 Subject: [PATCH 13/20] Fix styling --- src/Requests/SoapRequest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Requests/SoapRequest.php b/src/Requests/SoapRequest.php index 8dc47fd..6884241 100644 --- a/src/Requests/SoapRequest.php +++ b/src/Requests/SoapRequest.php @@ -35,7 +35,7 @@ public function request(string $method, array $requestBody, bool $convertToSoap 'SOAP REQUEST SUCCESS:'. "\nSOAP method: ".$method. property_exists($this->soapClient, '__last_request') - ? "\nSOAP request start***".preg_replace("#.+#", '*****', $this->soapClient->__last_request).'***SOAP request end' + ? "\nSOAP request start***".preg_replace('#.+#', '*****', $this->soapClient->__last_request).'***SOAP request end' : '' ); } @@ -74,7 +74,7 @@ public function request(string $method, array $requestBody, bool $convertToSoap "\nSOAP method: ".$method. ( property_exists($this->soapClient, '__last_request') - ? "\nSOAP request start***".preg_replace("#.+#", '*****', $this->soapClient->__last_request).'***SOAP request end' + ? "\nSOAP request start***".preg_replace('#.+#', '*****', $this->soapClient->__last_request).'***SOAP request end' : '' ).( property_exists($this->soapClient, '__last_response') From 8547b0048c43fbe85241afb902f96200eef774c8 Mon Sep 17 00:00:00 2001 From: Andrii Hazhur Date: Wed, 30 Aug 2023 15:06:43 +0300 Subject: [PATCH 14/20] fix --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index da55d24..8f4cb59 100644 --- a/composer.json +++ b/composer.json @@ -18,7 +18,7 @@ "require": { "php": "^7.4|^8.0|^8.1|^8.2", "spatie/laravel-package-tools": "^1.9.2", - "illuminate/contracts": "^9.0|^10.0", + "illuminate/contracts": "^8.0|^9.0|^10.0", "guzzlehttp/guzzle": "^7.0.1", "ext-soap": "*" }, From 5c69f653dcf1eb0998d8d7d70a4a05a624a419f0 Mon Sep 17 00:00:00 2001 From: Dmitry Filatov Date: Wed, 30 Aug 2023 16:26:22 +0300 Subject: [PATCH 15/20] fix: check param exists, add floppy class --- src/Traits/Soap/SoapImportApis.php | 2 +- src/Types/VirtualFloppyRemoteDeviceBackingInfo.php | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 src/Types/VirtualFloppyRemoteDeviceBackingInfo.php diff --git a/src/Traits/Soap/SoapImportApis.php b/src/Traits/Soap/SoapImportApis.php index 128ec9f..95f2d45 100644 --- a/src/Traits/Soap/SoapImportApis.php +++ b/src/Traits/Soap/SoapImportApis.php @@ -206,7 +206,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation ], 'firmware' => $configSpec->firmware ?? null, 'nestedHVEnabled' => $configSpec->nestedHVEnabled ?? null, - 'sgxInfo' => $configSpec->sgxInfo ? [ + 'sgxInfo' => isset($configSpec->sgxInfo) ? [ 'epcSize' => $configSpec->sgxInfo->epcSize ?? null, 'flcMode' => $configSpec->sgxInfo->flcMode ?? null, 'lePubKeyHash' => $configSpec->sgxInfo->lePubKeyHash ?? null, diff --git a/src/Types/VirtualFloppyRemoteDeviceBackingInfo.php b/src/Types/VirtualFloppyRemoteDeviceBackingInfo.php new file mode 100644 index 0000000..098a7cd --- /dev/null +++ b/src/Types/VirtualFloppyRemoteDeviceBackingInfo.php @@ -0,0 +1,8 @@ + Date: Fri, 1 Sep 2023 11:33:39 +0300 Subject: [PATCH 16/20] fix: check obj is not an array --- src/Traits/Soap/SoapImportApis.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Traits/Soap/SoapImportApis.php b/src/Traits/Soap/SoapImportApis.php index 95f2d45..1b2e4f8 100644 --- a/src/Traits/Soap/SoapImportApis.php +++ b/src/Traits/Soap/SoapImportApis.php @@ -62,7 +62,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation $extraConfig = []; if (isset($configSpec->extraConfig)) { // sometimes there is only one level of nesting - if (property_exists($configSpec->extraConfig, 'key')) { + if (!array($configSpec->extraConfig) && property_exists($configSpec->extraConfig, 'key')) { $extraConfig['key'] = $configSpec->extraConfig->key; $extraConfig['value:string'] = $configSpec->extraConfig->value->_value ?? ''; // but sometimes there are several From 157cf0629db90f8384bff23be8f4011194e12371 Mon Sep 17 00:00:00 2001 From: Dmitry Filatov Date: Fri, 1 Sep 2023 12:23:11 +0300 Subject: [PATCH 17/20] fix: check obj is not an array --- src/Traits/Soap/SoapImportApis.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Traits/Soap/SoapImportApis.php b/src/Traits/Soap/SoapImportApis.php index 1b2e4f8..e385442 100644 --- a/src/Traits/Soap/SoapImportApis.php +++ b/src/Traits/Soap/SoapImportApis.php @@ -62,7 +62,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation $extraConfig = []; if (isset($configSpec->extraConfig)) { // sometimes there is only one level of nesting - if (!array($configSpec->extraConfig) && property_exists($configSpec->extraConfig, 'key')) { + if (!is_array($configSpec->extraConfig) && property_exists($configSpec->extraConfig, 'key')) { $extraConfig['key'] = $configSpec->extraConfig->key; $extraConfig['value:string'] = $configSpec->extraConfig->value->_value ?? ''; // but sometimes there are several From ef48869a4479562c101346532ea066f1809c1c4f Mon Sep 17 00:00:00 2001 From: Dmitry Filatov Date: Mon, 11 Sep 2023 13:40:55 +0300 Subject: [PATCH 18/20] fix: check prop exists --- src/Traits/Soap/SoapImportApis.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Traits/Soap/SoapImportApis.php b/src/Traits/Soap/SoapImportApis.php index e385442..9337e31 100644 --- a/src/Traits/Soap/SoapImportApis.php +++ b/src/Traits/Soap/SoapImportApis.php @@ -186,7 +186,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation 'networkBootProtocol' => $configSpec->bootOptions->networkBootProtocol ?? null, ] : null, 'vAppConfig' => [ - 'product' => $configSpec->vAppConfig->product ? [ + 'product' => isset($configSpec->vAppConfig->product) ? [ 'operation' => $configSpec->vAppConfig->product->operation ?? null, 'info' => $configSpec->vAppConfig->product->info ? [ 'key' => $configSpec->vAppConfig->product->info->key ?? null, From 9e031976c4b381beebede97cd119f37cf74da68b Mon Sep 17 00:00:00 2001 From: Dmitry Filatov Date: Fri, 22 Sep 2023 15:18:38 +0300 Subject: [PATCH 19/20] fix: check props exists --- src/Traits/Soap/SoapImportApis.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Traits/Soap/SoapImportApis.php b/src/Traits/Soap/SoapImportApis.php index 9337e31..5f7dab0 100644 --- a/src/Traits/Soap/SoapImportApis.php +++ b/src/Traits/Soap/SoapImportApis.php @@ -115,14 +115,14 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation 'version' => $configSpec->version ?? null, 'uuid' => $configSpec->uuid ?? null, 'guestId' => $configSpec->guestId ?? null, - 'files' => $configSpec->files ? new VirtualMachineFileInfo([ + 'files' => isset($configSpec->files) ? new VirtualMachineFileInfo([ 'vmPathName' => $configSpec->files->vmPathName ?? null, 'snapshotDirectory' => $configSpec->files->snapshotDirectory ?? null, 'suspendDirectory' => $configSpec->files->suspendDirectory ?? null, 'logDirectory' => $configSpec->files->logDirectory ?? null, 'ftMetadataDirectory' => $configSpec->files->ftMetadataDirectory ?? null, ]) : null, - 'tools' => $configSpec->tools ? new ToolsConfigInfo([ + 'tools' => isset($configSpec->tools) ? new ToolsConfigInfo([ 'toolsVersion' => $configSpec->tools->toolsVersion ?? null, 'toolsInstallType' => $configSpec->tools->toolsInstallType ?? null, 'afterPowerOn' => $configSpec->tools->afterPowerOn ?? null, @@ -138,7 +138,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation 'lastInstallInfo' => $configSpec->tools->lastInstallInfo ?? null, ]) : null, - 'flags' => $configSpec->flags ? new VirtualMachineFlagInfo([ + 'flags' => isset($configSpec->flags) ? new VirtualMachineFlagInfo([ 'disableAcceleration' => $configSpec->flags->disableAcceleration ?? null, 'enableLogging' => $configSpec->flags->enableLogging ?? null, 'useToe' => $configSpec->flags->useToe ?? null, @@ -157,7 +157,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation 'vvtdEnabled' => $configSpec->flags->vvtdEnabled ?? null, 'vbsEnabled' => $configSpec->flags->vbsEnabled ?? null, ]) : null, - 'numCPUs' => $configSpec->numCPUs ?? null, + 'numCPUs' => isset($configSpec->numCPUs) ?? null, 'numCoresPerSocket' => $configSpec->numCoresPerSocket ?? null, 'memoryMB' => $configSpec->memoryMB ?? null, 'memoryHotAddEnabled' => $configSpec->memoryHotAddEnabled ?? null, @@ -176,7 +176,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation ] : null, ] : null, 'extraConfig' => \count($extraConfig) > 0 ? $extraConfig : null, - 'bootOptions' => $configSpec->bootOptions ? [ + 'bootOptions' => isset($configSpec->bootOptions) ? [ 'bootDelay' => $configSpec->bootOptions->bootDelay ?? null, 'enterBIOSSetup' => $configSpec->bootOptions->enterBIOSSetup ?? null, 'efiSecureBootEnabled' => $configSpec->bootOptions->efiSecureBootEnabled, From f2cb00d73352b6a262ad4d02aece92db7d648c8d Mon Sep 17 00:00:00 2001 From: Dmitry Filatov Date: Fri, 29 Sep 2023 13:06:14 +0300 Subject: [PATCH 20/20] fix: remove wrong check --- src/Traits/Soap/SoapImportApis.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Traits/Soap/SoapImportApis.php b/src/Traits/Soap/SoapImportApis.php index 5f7dab0..eec7d7f 100644 --- a/src/Traits/Soap/SoapImportApis.php +++ b/src/Traits/Soap/SoapImportApis.php @@ -157,7 +157,7 @@ public function importVApp(string $resourcePoolId, $entityConfig, $instantiation 'vvtdEnabled' => $configSpec->flags->vvtdEnabled ?? null, 'vbsEnabled' => $configSpec->flags->vbsEnabled ?? null, ]) : null, - 'numCPUs' => isset($configSpec->numCPUs) ?? null, + 'numCPUs' => $configSpec->numCPUs ?? null, 'numCoresPerSocket' => $configSpec->numCoresPerSocket ?? null, 'memoryMB' => $configSpec->memoryMB ?? null, 'memoryHotAddEnabled' => $configSpec->memoryHotAddEnabled ?? null,