Code Duplication    Length = 3-5 lines in 2 locations

src/Client.php 2 locations

@@ 343-347 (lines=5) @@
340
            $response = $this->adapter->end($this->adapter->start($request));
341
        }
342
343
        if (($this->cacheMode === self::CACHE_MODE_REFRESH
344
                || $this->cacheMode & self::CACHE_MODE_GET)
345
                && $request->getMethod() === 'GET') {
346
            $this->cache->set($request, $response);
347
        }
348
349
        return $response;
350
    }
@@ 404-406 (lines=3) @@
401
402
        list($this->accessToken, $this->refreshToken, $expires) = Authentication::parseTokenResponse($response);
403
404
        if ($this->cache === self::CACHE_MODE_REFRESH || $this->cacheMode & self::CACHE_MODE_TOKEN) {
405
            $this->cache->set($request, $response, $expires);
406
        }
407
    }
408
409
    /**