Skip to content

Commit 9bdf0ee

Browse files
authored
Merge pull request #23020 from nextcloud/disable-notify-self-check
add option to disable notify self check
2 parents d15179f + a79f960 commit 9bdf0ee

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

apps/files_external/lib/Command/Notify.php

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,11 @@ protected function configure() {
8585
InputOption::VALUE_REQUIRED,
8686
'The directory in the storage to listen for updates in',
8787
'/'
88+
)->addOption(
89+
'no-self-check',
90+
'',
91+
InputOption::VALUE_NONE,
92+
'Disable self check on startup'
8893
);
8994
parent::configure();
9095
}
@@ -138,7 +143,11 @@ protected function execute(InputInterface $input, OutputInterface $output): int
138143

139144
$path = trim($input->getOption('path'), '/');
140145
$notifyHandler = $storage->notify($path);
141-
$this->selfTest($storage, $notifyHandler, $verbose, $output);
146+
147+
if (!$input->getOption('no-self-check')) {
148+
$this->selfTest($storage, $notifyHandler, $verbose, $output);
149+
}
150+
142151
$notifyHandler->listen(function (IChange $change) use ($mount, $verbose, $output) {
143152
if ($verbose) {
144153
$this->logUpdate($change, $output);

0 commit comments

Comments
 (0)