Skip to content

Commit

Permalink
Merge pull request #32 from Xelon-AG/feat/import
Browse files Browse the repository at this point in the history
  • Loading branch information
tonkoshkurik authored Sep 20, 2023
2 parents 079a730 + ef48869 commit 4bd4dab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Traits/Soap/SoapImportApis.php
Original file line number Diff line number Diff line change
Expand Up @@ -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 (!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
Expand Down Expand Up @@ -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,
Expand Down

0 comments on commit 4bd4dab

Please sign in to comment.