mirror of
https://github.com/nextcloud/server.git
synced 2026-06-08 16:26:59 -04:00
fix(core): Make OC_PASS actually work for occ user:auth-tokens:add --password-from-env
Signed-off-by: provokateurin <kate@provokateurin.de>
This commit is contained in:
parent
d02223b6cc
commit
ab9328a17c
1 changed files with 2 additions and 2 deletions
|
|
@ -62,9 +62,9 @@ class Add extends Command {
|
|||
}
|
||||
|
||||
if ($input->getOption('password-from-env')) {
|
||||
$password = getenv('NC_PASS') ?? getenv('OC_PASS');
|
||||
$password = getenv('NC_PASS') ?: getenv('OC_PASS');
|
||||
if (!$password) {
|
||||
$output->writeln('<error>--password-from-env given, but NC_PASS is empty!</error>');
|
||||
$output->writeln('<error>--password-from-env given, but NC_PASS/OC_PASS is empty!</error>');
|
||||
return 1;
|
||||
}
|
||||
} elseif ($input->isInteractive()) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue