Conditions | 1 |
Paths | 1 |
Total Lines | 14 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
38 | public static function send(array $options){ |
||
39 | $mail = static::instance(); |
||
40 | |||
41 | $options = array_merge([ |
||
|
|||
42 | 'to' => false, |
||
43 | 'from' => false, |
||
44 | 'replyTo' => false, |
||
45 | 'subject' => false, |
||
46 | 'message' => false, |
||
47 | 'attachments' => [], |
||
48 | ],$options); |
||
49 | |||
50 | return $mail->send(new Envelope($option)); |
||
51 | } |
||
52 | |||
56 |
This check looks for variable assignements that are either overwritten by other assignments or where the variable is not used subsequently.
Both the
$myVar
assignment in line 1 and the$higher
assignment in line 2 are dead. The first because$myVar
is never used and the second because$higher
is always overwritten for every possible time line.