Code Duplication    Length = 10-10 lines in 2 locations

src/ArrayStore.php 2 locations

@@ 89-98 (lines=10) @@
86
    /**
87
     * {@inheritdoc}
88
     */
89
    public function get($key, $default = null)
90
    {
91
        KeyUtil::validate($key);
92
93
        if (!array_key_exists($key, $this->array)) {
94
            return $default;
95
        }
96
97
        return call_user_func($this->unserialize, $this->array[$key]);
98
    }
99
100
    /**
101
     * {@inheritdoc}
@@ 103-112 (lines=10) @@
100
    /**
101
     * {@inheritdoc}
102
     */
103
    public function getOrFail($key)
104
    {
105
        KeyUtil::validate($key);
106
107
        if (!array_key_exists($key, $this->array)) {
108
            throw NoSuchKeyException::forKey($key);
109
        }
110
111
        return call_user_func($this->unserialize, $this->array[$key]);
112
    }
113
114
    /**
115
     * {@inheritdoc}