GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

InvalidUrl::couldNotDetermineHost()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 3
nc 1
nop 1
dl 0
loc 6
ccs 0
cts 3
cp 0
crap 2
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
namespace LiquidWeb\SslCertificate\Exceptions;
4
5
use Exception;
6
7
class InvalidUrl extends Exception
8
{
9
    use TrackDomainTrait;
10
11 1
    public static function couldNotValidate(string $url): self
12
    {
13 1
        $exception = new static("String `{$url}` is not a valid url.");
14
15 1
        return $exception;
16
    }
17
18
    public static function couldNotDetermineHost(string $url): self
19
    {
20
        $exception = new static("Could not determine host from url `{$url}`.");
21
22
        return $exception;
23
    }
24
25 1
    public static function couldNotResolveDns(string $hostName): self
26
    {
27 1
        $exception = new static("The domain `{$hostName}` does not have a valid DNS record.");
28 1
        $exception->setErrorDomain($hostName);
29
30 1
        return $exception;
31
    }
32
}
33