Skip to content

Commit 5f98975

Browse files
authored
Prevent "Overwrite the existing configuration for ...?" question
Duplication for PR #26818
1 parent b9c13fd commit 5f98975

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

setup/src/Magento/Setup/Console/Command/ConfigSetCommand.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,11 @@ protected function execute(InputInterface $input, OutputInterface $output)
8484
$commandOptions[$option->getName()] = false;
8585

8686
$currentValue = $this->deploymentConfig->get($option->getConfigPath());
87-
if (($currentValue !== null) && ($inputOptions[$option->getName()] !== null)) {
87+
if (
88+
($currentValue !== null) &&
89+
($inputOptions[$option->getName()] !== null) &&
90+
($inputOptions[$option->getName()] !== $currentValue)
91+
) {
8892
$dialog = $this->getHelperSet()->get('question');
8993
$question = new Question(
9094
'<question>Overwrite the existing configuration for ' . $option->getName() . '?[Y/n]</question>',

0 commit comments

Comments
 (0)