diff options
author | Joas Schilling <coding@schilljs.com> | 2020-06-26 15:12:11 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2020-06-26 15:12:11 +0200 |
commit | d7c0b9cced2dff16e4e05507ac58cf8664a6aafc (patch) | |
tree | bb136f0e797986da6e789bf2bf5e9f0370002d26 /apps/encryption/lib/Command/EnableMasterKey.php | |
parent | ab21d69903c4360cbce59741624b6e765e3bd35f (diff) | |
download | nextcloud-server-d7c0b9cced2dff16e4e05507ac58cf8664a6aafc.tar.gz nextcloud-server-d7c0b9cced2dff16e4e05507ac58cf8664a6aafc.zip |
Also always return in app commands
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'apps/encryption/lib/Command/EnableMasterKey.php')
-rw-r--r-- | apps/encryption/lib/Command/EnableMasterKey.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/encryption/lib/Command/EnableMasterKey.php b/apps/encryption/lib/Command/EnableMasterKey.php index 4b1a5219c11..b1e7319384a 100644 --- a/apps/encryption/lib/Command/EnableMasterKey.php +++ b/apps/encryption/lib/Command/EnableMasterKey.php @@ -62,7 +62,7 @@ class EnableMasterKey extends Command { ->setDescription('Enable the master key. Only available for fresh installations with no existing encrypted data! There is also no way to disable it again.'); } - protected function execute(InputInterface $input, OutputInterface $output) { + protected function execute(InputInterface $input, OutputInterface $output): int { $isAlreadyEnabled = $this->util->isMasterKeyEnabled(); if ($isAlreadyEnabled) { @@ -76,7 +76,9 @@ class EnableMasterKey extends Command { $output->writeln('Master key successfully enabled.'); } else { $output->writeln('aborted.'); + return 1; } } + return 0; } } |