From 5587c2ea98e663b1bff30c390e0e44b1fd128785 Mon Sep 17 00:00:00 2001 From: S-Cart Date: Sun, 30 Jan 2022 18:59:32 +0700 Subject: [PATCH] Update handle exception --- app/Exceptions/Handler.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php index 85779819..fdf90d27 100644 --- a/app/Exceptions/Handler.php +++ b/app/Exceptions/Handler.php @@ -36,10 +36,8 @@ class Handler extends ExceptionHandler public function report(Throwable $exception) { if ($this->shouldReport($exception)) { - $msg = "```". $exception->getMessage().'```'.PHP_EOL; - $msg .= "*File* `".$exception->getFile()."`, *Line:* ".$exception->getLine().", *Code:* ".$exception->getCode().PHP_EOL.'URL= '.url()->current(); - if (function_exists('sc_report')) { - sc_report($msg); + if (function_exists('sc_handle_exception')) { + sc_handle_exception($exception); } } parent::report($exception);