- Issue created by @jonathan_hunt
- Assigned to sarwan
- Status changed to Needs review
3 months ago 5:18am 4 April 2024 - 🇮🇳India sarwan
Hi @jonathan_hunt,
I have fixed this issue "PHP Fatal error" and also attached patch ,
please review and verify.
PHP Fatal error: Declaration of Drupal\monolog_loki\Logger\Formatter\LokiFormatter::format(array $record): array must be compatible with Itspire\MonologLoki\Formatter\LokiFormatter::format(Monolog\LogRecord $record): array in /app/web/modules/custom/monolog_loki/src/Logger/Formatter/LokiFormatter.php on line 54
Running under Drupal 10.
At https://git.drupalcode.org/project/monolog_loki/-/blob/1.x/src/Logger/Fo..., need to change LokiFormatter format(array $record)
to LogRecord $record
and import the class use Monolog\LogRecord;
Needs review
1.0
Code
Hi @jonathan_hunt,
I have fixed this issue "PHP Fatal error" and also attached patch ,
please review and verify.