Fix various code.

This commit is contained in:
James Cole
2025-05-27 17:06:15 +02:00
parent d8f512ca3a
commit 2cb14f6b72
123 changed files with 581 additions and 500 deletions

View File

@@ -34,6 +34,8 @@ use GuzzleHttp\Exception\GuzzleException;
use GuzzleHttp\Exception\RequestException;
use JsonException;
use function Safe\json_encode;
/**
* Class StandardWebhookSender
*/
@@ -81,7 +83,7 @@ class StandardWebhookSender implements WebhookSenderInterface
app('log')->debug(sprintf('Trying to send webhook message #%d', $this->message->id));
try {
$json = \Safe\json_encode($this->message->message, JSON_THROW_ON_ERROR);
$json = json_encode($this->message->message, JSON_THROW_ON_ERROR);
} catch (JsonException $e) {
app('log')->error('Did not send message because of a JSON error.');
app('log')->error($e->getMessage());