mirror of
https://github.com/Seldaek/monolog.git
synced 2025-10-26 18:16:24 +01:00
TelegramBotHandler: skipping messages containing only whitespace (#1992)
#fixes https://github.com/Seldaek/monolog/issues/1991
This commit is contained in:
@@ -253,6 +253,10 @@ class TelegramBotHandler extends AbstractProcessingHandler
|
||||
|
||||
protected function sendCurl(string $message): void
|
||||
{
|
||||
if ('' === trim($message)) {
|
||||
return;
|
||||
}
|
||||
|
||||
$ch = curl_init();
|
||||
$url = self::BOT_API . $this->apiKey . '/SendMessage';
|
||||
curl_setopt($ch, CURLOPT_URL, $url);
|
||||
|
||||
Reference in New Issue
Block a user