@@ -38,7 +38,7 @@ discard block |
||
38 | 38 | <p>Enter this ID to receive your verification code below.</p> |
39 | 39 | HTML, |
40 | 40 | 'fields' => [ |
41 | - ['field' => 'bot_token', 'prompt' => 'Please enter your Telegram bot token:'], |
|
41 | + [ 'field' => 'bot_token', 'prompt' => 'Please enter your Telegram bot token:' ], |
|
42 | 42 | ], |
43 | 43 | ]; |
44 | 44 | public function __construct( |
@@ -49,10 +49,10 @@ discard block |
||
49 | 49 | parent::__construct($appConfig); |
50 | 50 | } |
51 | 51 | |
52 | - #[\Override] |
|
53 | - public function send(string $identifier, string $message, array $extra = []): void { |
|
52 | + #[\Override ] |
|
53 | + public function send(string $identifier, string $message, array $extra = [ ]): void { |
|
54 | 54 | if (empty($message)) { |
55 | - $message = $this->l10n->t('`%s` is your Nextcloud verification code.', [$extra['code']]); |
|
55 | + $message = $this->l10n->t('`%s` is your Nextcloud verification code.', [ $extra[ 'code' ] ]); |
|
56 | 56 | } |
57 | 57 | $this->logger->debug("sending telegram message to $identifier, message: $message"); |
58 | 58 | $botToken = $this->getBotToken(); |
@@ -71,10 +71,10 @@ discard block |
||
71 | 71 | $this->logger->debug("telegram message to chat $identifier sent"); |
72 | 72 | } |
73 | 73 | |
74 | - #[\Override] |
|
74 | + #[\Override ] |
|
75 | 75 | public function cliConfigure(InputInterface $input, OutputInterface $output): int { |
76 | 76 | $helper = new QuestionHelper(); |
77 | - $tokenQuestion = new Question(self::SCHEMA['fields'][0]['prompt'] . ' '); |
|
77 | + $tokenQuestion = new Question(self::SCHEMA[ 'fields' ][ 0 ][ 'prompt' ].' '); |
|
78 | 78 | $token = $helper->ask($input, $output, $tokenQuestion); |
79 | 79 | $this->setBotToken($token); |
80 | 80 | $output->writeln("Using $token."); |