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.
Passed
Push — master ( 02a544...21c789 )
by Odiseo
03:34
created

BaseSyncCommand   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 6
dl 0
loc 17
rs 10
c 0
b 0
f 0
wmc 4

1 Method

Rating   Name   Duplication   Size   Complexity  
A showError() 0 7 4
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Odiseo\SyliusMailchimpPlugin\Command;
6
7
use Symfony\Component\Console\Command\Command;
8
use Symfony\Component\Console\Style\SymfonyStyle;
9
10
abstract class BaseSyncCommand extends Command
11
{
12
    /**
13
     * @var SymfonyStyle
14
     */
15
    protected $io;
16
17
    /**
18
     * @param array $response
19
     */
20
    protected function showError(array $response)
21
    {
22
        $this->io->error('Status: ' . $response['status'] . ', Detail: ' . $response['detail']);
23
24
        if (isset($response['errors']) && count($response['errors']) > 0) {
25
            foreach ($response['errors'] as $error) {
26
                $this->io->listing($error);
27
            }
28
        }
29
    }
30
}
31