异常上下文保留请求参数
parent
6f598af1fc
commit
bc7989f9ef
|
|
@ -31,6 +31,22 @@ class Handler extends ExceptionHandler
|
|||
'password_confirmation',
|
||||
];
|
||||
|
||||
/**
|
||||
* Get the default context variables for logging.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
protected function context()
|
||||
{
|
||||
try {
|
||||
return array_merge(parent::context(), [
|
||||
'params' => request()->except($this->dontFlash),
|
||||
]);
|
||||
} catch (Throwable $e) {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Register the exception handling callbacks for the application.
|
||||
*
|
||||
|
|
|
|||
Loading…
Reference in New Issue