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.

NowPlaying::setAlbumArtist()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * (c) Christian Gripp <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Core23\LastFm\Model;
13
14
final class NowPlaying
15
{
16
    /**
17
     * @var string
18
     */
19
    private $artist;
20
21
    /**
22
     * @var string
23
     */
24
    private $track;
25
26
    /**
27
     * @var string
28
     */
29
    private $album;
30
31
    /**
32
     * @var int|null
33
     */
34
    private $trackNumber;
35
36
    /**
37
     * @var string|null
38
     */
39
    private $context;
40
41
    /**
42
     * @var string|null
43
     */
44
    private $mbid;
45
46
    /**
47
     * @var string|null
48
     */
49
    private $duration;
50
51
    /**
52
     * @var string|null
53
     */
54
    private $albumArtist;
55
56
    public function __construct(string $artist, string $track)
57
    {
58
        $this->artist = $artist;
59
        $this->track  = $track;
60
    }
61
62
    public function setAlbum(string $album): void
63
    {
64
        $this->album = $album;
65
    }
66
67
    public function setTrackNumber(?int $trackNumber): void
68
    {
69
        $this->trackNumber = $trackNumber;
70
    }
71
72
    public function setContext(?string $context): void
73
    {
74
        $this->context = $context;
75
    }
76
77
    public function setMbid(?string $mbid): void
78
    {
79
        $this->mbid = $mbid;
80
    }
81
82
    public function setDuration(?string $duration): void
83
    {
84
        $this->duration = $duration;
85
    }
86
87
    public function setAlbumArtist(?string $albumArtist): void
88
    {
89
        $this->albumArtist = $albumArtist;
90
    }
91
92
    public function toArray(): array
93
    {
94
        return [
95
            'artist'      => $this->artist,
96
            'track'       => $this->track,
97
            'album'       => $this->album,
98
            'trackNumber' => $this->trackNumber,
99
            'context'     => $this->context,
100
            'mbid'        => $this->mbid,
101
            'duration'    => $this->duration,
102
            'albumArtist' => $this->albumArtist,
103
        ];
104
    }
105
}
106