diff --git a/commands/NewchatmembersCommand.php b/commands/NewchatmembersCommand.php index 66a0625..9377835 100644 --- a/commands/NewchatmembersCommand.php +++ b/commands/NewchatmembersCommand.php @@ -96,7 +96,7 @@ private function refreshWelcomeMessage(array $new_users): ServerResponse $text = "Welcome {$new_users_text} to the {$this->group_name} group\n"; $text .= 'Please remember that this is NOT the Telegram Support Chat.' . PHP_EOL; - $text .= 'Read the Rules that apply here.'; + $text .= 'Read the Rules that apply here.'; $welcome_message_sent = $this->replyToChat($text, ['parse_mode' => 'HTML', 'disable_web_page_preview' => true]); if (!$welcome_message_sent->isOk()) { diff --git a/commands/StartCommand.php b/commands/StartCommand.php index 9e9984b..a613234 100644 --- a/commands/StartCommand.php +++ b/commands/StartCommand.php @@ -53,6 +53,10 @@ class StartCommand extends SystemCommand */ public function execute(): ServerResponse { + if ('rules' === $this->getMessage()->getText(true)) { + return $this->getTelegram()->executeCommand('rules'); + } + return $this->getTelegram()->executeCommand('help'); } }