Skip to content

Commit

Permalink
Add redispatchOptions() in updatedb (#4755)
Browse files Browse the repository at this point in the history
* Add redispatchOptions() in updatedb

* More redispatchOptions()

* Unstrict
  • Loading branch information
weitzman committed May 13, 2021
1 parent 4754830 commit e343e01
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Commands/core/SiteInstallCommands.php
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ public function post($result, CommandData $commandData)
if ($config = $commandData->input()->getOption('config-dir') && Comparator::lessThan(self::getVersion(), '8.6')) {
// Set the destination site UUID to match the source UUID, to bypass a core fail-safe.
$source_storage = new FileStorage($config);
$options = ['yes' => true];
$options = array_merge(Drush::redispatchOptions(), ['yes' => true, 'strict' => 0]);
$selfRecord = $this->siteAliasManager()->getSelf();

$process = $this->processManager()->drush($selfRecord, 'config-set', ['system.site', 'uuid', $source_storage->read('system.site')['uuid']], $options);
Expand Down
2 changes: 2 additions & 0 deletions src/Commands/core/UpdateDBCommands.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@ public function updatedb($options = ['cache-clear' => true, 'entity-updates' =>
// @see https://github.com/drush-ops/drush/pull/3855.
'no-entity-updates' => !$options['entity-updates'],
'no-post-updates' => !$options['post-updates'],
'strict' => 0,
];
$status_options = array_merge(Drush::redispatchOptions(), $status_options);
$process = $this->processManager()->drush($this->siteAliasManager()->getSelf(), 'updatedb:status', [], $status_options);
$process->mustRun();
if ($output = $process->getOutput()) {
Expand Down

0 comments on commit e343e01

Please sign in to comment.