1 | <?php |
||
7 | class Roster |
||
8 | { |
||
9 | /** |
||
10 | * @var string |
||
11 | */ |
||
12 | public $type; |
||
13 | |||
14 | /** |
||
15 | * @var string |
||
16 | */ |
||
17 | public $id; |
||
18 | |||
19 | /** |
||
20 | * @var null|string |
||
21 | */ |
||
22 | private $shardId; |
||
23 | |||
24 | /** |
||
25 | * @var int|null |
||
26 | */ |
||
27 | private $score; |
||
28 | |||
29 | /** |
||
30 | * @var bool|null |
||
31 | */ |
||
32 | private $won; |
||
33 | |||
34 | /** |
||
35 | * @var null|Participants |
||
36 | */ |
||
37 | private $participants; |
||
38 | |||
39 | 1 | private function __construct( |
|
54 | |||
55 | 1 | public static function createFromArray(array $roster): self |
|
80 | } |
||
81 |
This check looks for the bodies of
if
statements that have no statements or where all statements have been commented out. This may be the result of changes for debugging or the code may simply be obsolete.These
if
bodies can be removed. If you have an empty if but statements in theelse
branch, consider inverting the condition.could be turned into
This is much more concise to read.