RequestException   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 2
Bugs 1 Features 0
Metric Value
eloc 5
c 2
b 1
f 0
dl 0
loc 27
ccs 6
cts 6
cp 1
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 9 1
A getBaseException() 0 3 1
1
<?php
2
3
namespace FtwSoft\NotificationChannels\Intercom\Exceptions;
4
5
use Throwable;
6
use GuzzleHttp\Exception\RequestException as BaseRequestException;
7
8
class RequestException extends IntercomException
9
{
10
    /**
11
     * @var BaseRequestException
12
     */
13
    private $baseException;
14
15
    /**
16
     * {@inheritdoc}
17
     */
18 2
    public function __construct(
19
        BaseRequestException $baseException,
20
        string $message = '',
21
        int $code = 0,
22
        ?Throwable $previous = null
23
    ) {
24 2
        $this->baseException = $baseException;
25
26 2
        parent::__construct($message, $code, $previous);
27 2
    }
28
29
    /**
30
     * @return BaseRequestException
31
     */
32 1
    public function getBaseException(): BaseRequestException
33
    {
34 1
        return $this->baseException;
35
    }
36
}
37