Skip to content

Commit 610b6d9

Browse files
hjuarez20enzolutions
authored andcommitted
[database:add] Hide the dbpass on interactive mode (#4041)
1 parent 6fe73b3 commit 610b6d9

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/Command/Database/AddCommand.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ protected function configure()
5656
->addOption(
5757
'password',
5858
null,
59-
InputOption::VALUE_REQUIRED,
59+
InputOption::VALUE_OPTIONAL,
6060
$this->trans('commands.database.add.options.password')
6161
)
6262
->addOption(
@@ -122,9 +122,8 @@ protected function interact(InputInterface $input, OutputInterface $output)
122122
$input->setOption('username', $username);
123123
$password = $input->getOption('password');
124124
if (!$password) {
125-
$password = $this->getIo()->ask(
126-
$this->trans('commands.database.add.questions.password'),
127-
''
125+
$password = $this->getIo()->askHiddenEmpty(
126+
$this->trans('commands.migrate.execute.questions.db-pass')
128127
);
129128
}
130129
$input->setOption('password', $password);

0 commit comments

Comments
 (0)