Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion src/Monolog/LogsHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
self::getSentryLogLevelFromMonologLevel($record['level']),
$record['message'],
[],
array_merge($record['context'], $record['extra'], ['sentry.origin' => 'auto.logger.monolog'])
$this->compileAttributes($record)

Check failure on line 69 in src/Monolog/LogsHandler.php

View workflow job for this annotation

GitHub Actions / PHPStan

Parameter #1 $record of method Sentry\Monolog\LogsHandler::compileAttributes() expects Monolog\LogRecord, array<string, mixed>|Monolog\LogRecord given.
);

return $this->bubble === false;
Expand Down Expand Up @@ -123,4 +123,9 @@
// Just in case so that the destructor can never fail.
}
}

protected function compileAttributes(LogRecord $record): array

Check failure on line 127 in src/Monolog/LogsHandler.php

View workflow job for this annotation

GitHub Actions / PHPStan

Method Sentry\Monolog\LogsHandler::compileAttributes() return type has no value type specified in iterable type array.
{
return array_merge($record['context'], $record['extra'], ['sentry.origin' => 'auto.logger.monolog']);

Check failure on line 129 in src/Monolog/LogsHandler.php

View workflow job for this annotation

GitHub Actions / PHPStan

Parameter #2 ...$arrays of function array_merge expects array, array|DateTimeImmutable|int|string|null given.

Check failure on line 129 in src/Monolog/LogsHandler.php

View workflow job for this annotation

GitHub Actions / PHPStan

Parameter #1 ...$arrays of function array_merge expects array, array|DateTimeImmutable|int|string|null given.
}
Comment thread
huangdijia marked this conversation as resolved.
}
Loading