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.

ArrayStorage::get()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 2
nc 2
nop 1
1
<?php
2
/**
3
 * 
4
 */
5
6
namespace Opensoft\Rollout\Storage;
7
8
/**
9
 * @author Richard Fullmer <[email protected]>
10
 */
11
class ArrayStorage implements StorageInterface
12
{
13
    /**
14
     * @var array
15
     */
16
    private $storage = array();
17
18
    /**
19
     * @param string $key
20
     * @return mixed|null
21
     */
22
    public function get($key)
23
    {
24
        return isset($this->storage[$key]) ? $this->storage[$key] : null;
25
    }
26
27
    /**
28
     * @param string $key
29
     * @param mixed $value
30
     */
31
    public function set($key, $value)
32
    {
33
        $this->storage[$key] = $value;
34
    }
35
36
    /**
37
     * @param string $key
38
     */
39
    public function remove($key)
40
    {
41
        if (isset($this->storage[$key])) {
42
            unset($this->storage[$key]);
43
        }
44
    }
45
} 
46