Handler   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 8
dl 0
loc 17
rs 10
c 0
b 0
f 0
wmc 3

1 Method

Rating   Name   Duplication   Size   Complexity  
A report() 0 7 3
1
<?php
2
3
namespace App\Exceptions;
4
5
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
6
use Illuminate\Support\Facades\App;
7
use LaravelEnso\Helpers\Exceptions\EnsoException;
8
use LaravelEnso\Sentry\Exceptions\Handler as Sentry;
9
use Throwable;
10
11
class Handler extends ExceptionHandler
12
{
13
    protected $dontReport = [
14
        EnsoException::class,
15
    ];
16
17
    protected $dontFlash = [
18
        'password', 'password_confirmation',
19
    ];
20
21
    public function report(Throwable $exception)
22
    {
23
        if (App::bound('sentry') && $this->shouldReport($exception)) {
24
            Sentry::report($exception);
25
        }
26
27
        parent::report($exception);
28
    }
29
30
    // public function register()
31
    // {
32
    //     $this->reportable(function (Throwable $e) {
33
    //
34
    //     });
35
    // }
36
}
37