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.

FileDeleteCommand::getCommitMessage()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
ccs 2
cts 2
cp 1
cc 1
nc 1
nop 0
crap 1
1
<?php declare(strict_types=1);
2
3
namespace ApiClients\Client\Github\CommandBus\Command\Repository\Contents;
4
5
use WyriHaximus\Tactician\CommandHandler\Annotations\Handler;
6
7
/**
8
 * @Handler("ApiClients\Client\Github\CommandBus\Handler\Repository\Contents\FileDeleteHandler")
9
 */
10
final class FileDeleteCommand
11
{
12
    /**
13
     * @var string
14
     */
15
    private $repository;
16
17
    /**
18
     * @var string
19
     */
20
    private $commitMessage;
21
22
    /**
23
     * @var string
24
     */
25
    private $url;
26
27
    /**
28
     * @var string
29
     */
30
    private $sha;
31
32
    /**
33
     * @var string
34
     */
35
    private $branch;
36
37
    /**
38
     * @param string $repository
39
     * @param string $commitMessage
40
     * @param string $url
41
     * @param string $sha
42
     * @param string $branch
43
     */
44 View Code Duplication
    public function __construct(
0 ignored issues
show
Duplication introduced by
This method seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
45
        string $repository,
46
        string $commitMessage,
47
        string $url,
48
        string $sha,
49
        string $branch = ''
50
    ) {
51
        $this->repository = $repository;
52
        $this->commitMessage = $commitMessage;
53
        $this->url = $url;
54
        $this->sha = $sha;
55
        $this->branch = $branch;
56
    }
57
58
    /**
59
     * @return string
60
     */
61
    public function getRepository(): string
62
    {
63
        return $this->repository;
64
    }
65
66
    /**
67
     * @return string
68
     */
69 3
    public function getCommitMessage(): string
70
    {
71 3
        return $this->commitMessage;
72
    }
73
74
    /**
75
     * @return string
76
     */
77 3
    public function getUrl(): string
78
    {
79 3
        return $this->url;
80
    }
81
82
    /**
83
     * @return string
84
     */
85 3
    public function getSha(): string
86
    {
87 3
        return $this->sha;
88
    }
89
90
    /**
91
     * @return string
92
     */
93 3
    public function getBranch(): string
94
    {
95 3
        return $this->branch;
96
    }
97
}
98