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.
Completed
Push — master ( 7bf065...13ae28 )
by Axel
02:07
created

YamlAbacLoader::load()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 1
b 0
f 0
cc 1
eloc 2
nc 1
nop 2
crap 1
1
<?php
2
3
namespace PhpAbac\Loader;
4
5
use Symfony\Component\Config\Loader\FileLoader;
6
use Symfony\Component\Yaml\Yaml;
7
8
class YamlAbacLoader extends FileLoader
9
{
10 9
    public function load($resource, $type = null)
11
    {
12 9
        return Yaml::parse(file_get_contents($resource));
13
    }
14
15
    public function supports($resource, $type = null)
16
    {
17
        return is_string($resource) && 'yml' === pathinfo(
18
            $resource,
19
            PATHINFO_EXTENSION
20
        );
21
    }
22
}