在webman-admin中自定义异常类,发现log出问题。

roczyl

查看了一下class ExceptionHandler implements ExceptionHandlerInterface,
发现
public function __construct($logger, $debug)
{
$this->logger = $logger;
$this->debug = $debug;
}

请问,自定的异常类,初始化是在哪里?$logger定义又应该在哪里呢?

386 1 0
1个回答

walkor

异常类在 vendor/workerman/webman-framework/src/support/App.phpexceptionResponse()方法里初始化的。
$loggervendor/workerman/webman-framework/src/support/Log.phpchannel()方法里初始化的

  • 暂无评论
🔝