public function getItem($key) { $item = $this->cachePool->getItem($key); if (!$item instanceof EncryptedItemDecorator) { return new EncryptedItemDecorator($item, $this->key); } return $item; }