Skip to content

Commit

Permalink
Merge pull request #111 from acquia/develop
Browse files Browse the repository at this point in the history
ACMS-1906: merge develop into main.
  • Loading branch information
rajeshreeputra authored Jul 24, 2023
2 parents 5a3f5c9 + c428adf commit 56d39d7
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/Helpers/Task/Steps/SiteInstall.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,18 +68,18 @@ public function execute(array $args = []): int {
"--site-name=$this->siteName",
"--account-pass=$this->password",
];

// Remove without-product-info from argument as it is only used internally.
unset($args['without-product-info']);

// Iterate arguments i.e options to prepare for site install.
foreach ($args as $key => $value) {
if (!in_array($key, [
'without-product-info',
'no-interaction',
])) {
if ($value != "true") {
$siteInstallCommand[] = "--" . $key . "=" . $value;
}
}
// Option no-interation then add suffix --yes to the command.
if (isset($args['no-interaction']) && $args['no-interaction']) {
$siteInstallCommand = array_merge($siteInstallCommand, ["--yes"]);
else {
$siteInstallCommand[] = "--" . $key;
}
}

return $this->drushCommand->prepare($siteInstallCommand)->run();
Expand Down

0 comments on commit 56d39d7

Please sign in to comment.