Conditions | 2 |
Paths | 3 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 6 |
Changes | 0 |
1 | <?php |
||
34 | public function handle(): void |
||
35 | { |
||
36 | $nfl = new NFL(new NFLHttpClient(), new DateTime('now', new DateTimeZone('US/Eastern'))); |
||
37 | |||
38 | try { |
||
39 | $printer = new Printer($this); |
||
40 | |||
41 | $printer->renderGamesList($nfl->getWeekGames()); |
||
42 | } catch (ErrorException $e) { |
||
43 | exit($this->line('Sorry, there was a problem fetching the remote data.')); |
||
44 | } |
||
47 |
This check looks for function or method calls that always return null and whose return value is used.
The method
getObject()
can return nothing but null, so it makes no sense to use the return value.The reason is most likely that a function or method is imcomplete or has been reduced for debug purposes.