diff options
Diffstat (limited to 'lib/Command/Room/Delete.php')
-rw-r--r-- | lib/Command/Room/Delete.php | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/lib/Command/Room/Delete.php b/lib/Command/Room/Delete.php index 986ca67a4..34b767cc3 100644 --- a/lib/Command/Room/Delete.php +++ b/lib/Command/Room/Delete.php @@ -27,21 +27,14 @@ namespace OCA\Talk\Command\Room; use OC\Core\Command\Base; use OCA\Talk\Exceptions\RoomNotFoundException; -use OCA\Talk\Manager; use OCA\Talk\Room; +use Stecman\Component\Symfony\Console\BashCompletion\CompletionContext; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; class Delete extends Base { - /** @var Manager */ - public $manager; - - public function __construct(Manager $manager) { - parent::__construct(); - - $this->manager = $manager; - } + use TRoomCommand; protected function configure(): void { $this @@ -74,4 +67,13 @@ class Delete extends Base { $output->writeln('<info>Room successfully deleted.</info>'); return 0; } + + public function completeArgumentValues($argumentName, CompletionContext $context) { + switch ($argumentName) { + case 'token': + return $this->completeTokenValues($context); + } + + return parent::completeArgumentValues($argumentName, $context); + } } |