Example #1
0
 public function execute(InputInterface $input, OutputInterface $output)
 {
     $backend = $input->getArgument('backend');
     try {
         $this->backendManager->enableBackend($backend);
         $output->writeln("Chat Backend '" . $backend . "' is enabled.");
     } catch (BackendNotFoundException $e) {
         $output->writeln("<error>Chat Backend does not exists.</error>");
     }
 }
Example #2
0
 /**
  * @param string $protocol
  * @return \OCA\Chat\IBackend
  */
 private function getBackend($protocol)
 {
     $this->backendManager->getBackendByProtocol($protocol);
 }