Skip to content

Commit

Permalink
Revert "LogRecord update for MonoLog Laravel 10 (#36)" (#39)
Browse files Browse the repository at this point in the history
This reverts commit 9ed167a.
  • Loading branch information
vpratfr authored Feb 28, 2023
1 parent 9ed167a commit 472ee85
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/DiscordLogger/LogHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
use MarvinLabs\DiscordLogger\Converters\SimpleRecordConverter;
use Monolog\Handler\AbstractProcessingHandler;
use Monolog\Logger as Monolog;
use Monolog\LogRecord;
use RuntimeException;
use function class_implements;

Expand All @@ -30,10 +29,8 @@ public function __construct(Container $container, Repository $config, array $cha
$this->recordToMessage = $this->createRecordConverter($container, $config);
}

public function write(LogRecord $record): void
public function write(array $record): void
{
$record = $record->toArray();

foreach($this->recordToMessage->buildMessages($record) as $message)
{
$this->discord->send($message);
Expand Down

0 comments on commit 472ee85

Please sign in to comment.