Code Duplication    Length = 9-9 lines in 2 locations

src/RedisProxy.php 2 locations

@@ 169-177 (lines=9) @@
166
     * @param string $key
167
     * @return string
168
     */
169
    public function get($key)
170
    {
171
        $this->init();
172
        $result = $this->driver->get($key);
173
        if ($this->driver instanceof Client) {
174
            $result = $result === null ? false : $result;
175
        }
176
        return $result;
177
    }
178
179
    public function del(...$key)
180
    {
@@ 207-215 (lines=9) @@
204
     * @param string $field
205
     * @return string|boolean false if hash field is not set
206
     */
207
    public function hget($key, $field)
208
    {
209
        $this->init();
210
        $result = $this->driver->hget($key, $field);
211
        if ($this->driver instanceof Client) {
212
            $result = $result === null ? false : $result;
213
        }
214
        return $result;
215
    }
216
217
    /**
218
     * Delete one or more hash fields, returns number of deleted fields