update: log api

This commit is contained in:
v2board
2023-05-24 01:08:13 +08:00
parent 4dc6d29076
commit 3752bed0d6
8 changed files with 203 additions and 66 deletions

View File

@ -0,0 +1,11 @@
<?php
namespace App\Logging;
class MysqlLogger
{
public function __invoke(array $config){
return tap(new \Monolog\Logger('mysql'), function ($logger) {
$logger->pushHandler(new MysqlLoggerHandler());
});
}
}