@@ 305-312 (lines=8) @@ | ||
302 | { |
|
303 | $key = $this->normalizeCacheKey($key); |
|
304 | $cacheItemPool = $this->sdk->getCacheItemPool(); |
|
305 | if (isset($cacheItemPool)) { |
|
306 | $cacheKey = $this->sdk->getCachePrefix() . $key; |
|
307 | if ($cacheItemPool->hasItem($cacheKey)) { |
|
308 | $cacheItem = $cacheItemPool->getItem($cacheKey); |
|
309 | $cacheData = $cacheItem->get(); |
|
310 | return $cacheData; |
|
311 | } |
|
312 | } |
|
313 | ||
314 | return false; |
|
315 | } |
|
@@ 327-335 (lines=9) @@ | ||
324 | { |
|
325 | $key = $this->normalizeCacheKey($key); |
|
326 | $cacheItemPool = $this->sdk->getCacheItemPool(); |
|
327 | if (isset($cacheItemPool)) { |
|
328 | $cacheKey = $this->sdk->getCachePrefix() . $key; |
|
329 | ||
330 | if (!$cacheItemPool->hasItem($cacheKey)) { |
|
331 | $cacheItem = $cacheItemPool->getItem($cacheKey); |
|
332 | $cacheItem->set($value); |
|
333 | $cacheItemPool->save($cacheItem); |
|
334 | } |
|
335 | } |
|
336 | } |
|
337 | ||
338 | /** |