<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace App\Exceptions; use Exception; use Illuminate\Database\Eloquent\ModelNotFoundException; use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler; use ModStart\Core\Exception\ExceptionReportHandleTrait; use Symfony\Component\HttpKernel\Exception\HttpException; use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; class Handler extends ExceptionHandler { use ExceptionReportHandleTrait; protected $dontReport = array(HttpException::class, ModelNotFoundException::class); public function report(Exception $rbEvf) { $this->errorReportCheck($rbEvf); parent::report($rbEvf); } public function render($v5ABp, Exception $e2YUV) { if ($e2YUV instanceof ModelNotFoundException) { $e2YUV = new NotFoundHttpException($e2YUV->getMessage(), $e2YUV); } return parent::render($v5ABp, $e2YUV); } protected function convertExceptionToResponse(Exception $e2YUV) { goto kkgob; TUMkb: return response()->view('errors.500', array('exception' => $e2YUV), 500); goto Qv_Pp; kkgob: $TxxBx = $this->getExceptionResponse($e2YUV); goto dW5zR; OTU9C: if (config('env.APP_DEBUG', true)) { return parent::convertExceptionToResponse($e2YUV); } goto TUMkb; dW5zR: if (null !== $TxxBx) { return $TxxBx; } goto OTU9C; Qv_Pp: } }