From 4d45add53eb0c6517351f5fc6cc76787f4325a40 Mon Sep 17 00:00:00 2001 From: netkas Date: Mon, 7 Oct 2024 19:33:26 -0400 Subject: [PATCH] Updated SendMessage --- src/TgBotLib/Methods/SendMessage.php | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/TgBotLib/Methods/SendMessage.php b/src/TgBotLib/Methods/SendMessage.php index 95ddd7d..e5d3366 100644 --- a/src/TgBotLib/Methods/SendMessage.php +++ b/src/TgBotLib/Methods/SendMessage.php @@ -20,16 +20,6 @@ */ public static function execute(Bot $bot, array $parameters=[]): Message { - if(!isset($parameters['chat_id'])) - { - throw new InvalidArgumentException('chat_id is required'); - } - - if(!isset($parameters['text'])) - { - throw new InvalidArgumentException('text is required'); - } - if(isset($parameters['parse_mode']) && $parameters['parse_mode'] instanceof ParseMode) { $parameters['parse_mode'] = $parameters['parse_mode']->value;