1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-10-23 01:26:11 +02:00

mb_* functions with BC

This commit is contained in:
vershinin_so
2019-07-08 11:05:19 +03:00
parent ada57dd4a1
commit c79d81ec28
27 changed files with 120 additions and 64 deletions

View File

@@ -13,6 +13,7 @@ namespace Monolog\Handler;
use Aws\Sqs\SqsClient;
use Monolog\Logger;
use Monolog\Utils;
/**
* Writes to any sqs queue.
@@ -51,8 +52,8 @@ class SqsHandler extends AbstractProcessingHandler
}
$messageBody = $record['formatted'];
if (strlen($messageBody) >= static::MAX_MESSAGE_SIZE) {
$messageBody = substr($messageBody, 0, static::HEAD_MESSAGE_SIZE);
if (Utils::strlen($messageBody) >= static::MAX_MESSAGE_SIZE) {
$messageBody = Utils::substr($messageBody, 0, static::HEAD_MESSAGE_SIZE);
}
$this->client->sendMessage([