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.

Check   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 33
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 10
dl 0
loc 33
rs 10
c 0
b 0
f 0
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A handle() 0 12 2
1
<?php
2
3
namespace ProtoneMedia\ApiHealth\Console;
4
5
use Illuminate\Console\Command;
6
use ProtoneMedia\ApiHealth\Checkers\Executor;
7
8
class Check extends Command
9
{
10
    /**
11
     * The name and signature of the console command.
12
     *
13
     * @var string
14
     */
15
    protected $signature = 'api-health:check {checkerClass}';
16
17
    /**
18
     * The console command description.
19
     *
20
     * @var string
21
     */
22
    protected $description = 'Run the given checker';
23
24
    /**
25
     * Displays the result of the given checker.
26
     *
27
     * @return null
28
     */
29
    public function handle()
30
    {
31
        $executor = Executor::make(
32
            $checkerClass = $this->argument('checkerClass')
0 ignored issues
show
Bug introduced by
It seems like $checkerClass = $this->argument('checkerClass') can also be of type array and null; however, parameter $checkerClass of ProtoneMedia\ApiHealth\Checkers\Executor::make() does only seem to accept string, maybe add an additional type check? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

32
            /** @scrutinizer ignore-type */ $checkerClass = $this->argument('checkerClass')
Loading history...
33
        );
34
35
        $this->info('Running checker: ' . $checkerClass);
0 ignored issues
show
Bug introduced by
Are you sure $checkerClass of type array|null|string can be used in concatenation? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

35
        $this->info('Running checker: ' . /** @scrutinizer ignore-type */ $checkerClass);
Loading history...
36
37
        if ($executor->passes()) {
38
            $this->info('Passes!');
39
        } else {
40
            $this->error('Fails! ' . $executor->getException()->getMessage());
41
        }
42
    }
43
}
44