diff --git a/src/Storage/Adapter/Apc.php b/src/Storage/Adapter/Apc.php index b380672f4..939fb588d 100644 --- a/src/Storage/Adapter/Apc.php +++ b/src/Storage/Adapter/Apc.php @@ -143,7 +143,6 @@ public function getIterator() $options = $this->getOptions(); $prefix = $options->getNamespace() . $options->getNamespaceSeparator(); $pattern = '/^' . preg_quote($prefix, '/') . '/'; - $format = 0; $baseIt = new BaseApcIterator('user', $pattern, 0, 1, \APC_LIST_ACTIVE); return new ApcIterator($this, $baseIt, $prefix); diff --git a/src/Storage/Adapter/Filesystem.php b/src/Storage/Adapter/Filesystem.php index 4454c7d05..4f0f5f385 100644 --- a/src/Storage/Adapter/Filesystem.php +++ b/src/Storage/Adapter/Filesystem.php @@ -193,8 +193,6 @@ public function clearByNamespace($namespace) . str_repeat(\DIRECTORY_SEPARATOR . $nsPrefix . '*', $options->getDirLevel()) . \DIRECTORY_SEPARATOR . $nsPrefix . '*'; $glob = new GlobIterator($path, $flags); - $time = time(); - $ttl = $options->getTtl(); ErrorHandler::start(); foreach ($glob as $pathname) { @@ -227,8 +225,6 @@ public function clearByPrefix($prefix) . str_repeat(\DIRECTORY_SEPARATOR . $nsPrefix . '*', $options->getDirLevel()) . \DIRECTORY_SEPARATOR . $nsPrefix . $prefix . '*'; $glob = new GlobIterator($path, $flags); - $time = time(); - $ttl = $options->getTtl(); ErrorHandler::start(); foreach ($glob as $pathname) { @@ -317,8 +313,6 @@ public function clearByTags(array $tags, $disjunction = false) . str_repeat(\DIRECTORY_SEPARATOR . $prefix . '*', $options->getDirLevel()) . \DIRECTORY_SEPARATOR . $prefix . '*.tag'; $glob = new GlobIterator($path, $flags); - $time = time(); - $ttl = $options->getTtl(); foreach ($glob as $pathname) { $diff = array_diff($tags, explode("\n", $this->getFileContent($pathname))); @@ -884,7 +878,6 @@ public function replaceItems(array $keyValuePairs) */ protected function internalSetItem(& $normalizedKey, & $value) { - $options = $this->getOptions(); $filespec = $this->getFileSpec($normalizedKey); $this->prepareDirectoryStructure($filespec); @@ -903,7 +896,6 @@ protected function internalSetItem(& $normalizedKey, & $value) */ protected function internalSetItems(array & $normalizedKeyValuePairs) { - $baseOptions = $this->getOptions(); $oldUmask = null; // create an associated array of files and contents to write diff --git a/src/Storage/Adapter/Memcached.php b/src/Storage/Adapter/Memcached.php index d0f5a955b..530bae039 100644 --- a/src/Storage/Adapter/Memcached.php +++ b/src/Storage/Adapter/Memcached.php @@ -302,7 +302,7 @@ protected function internalGetMetadatas(array & $normalizedKeys) throw $this->getExceptionByResultCode($this->memcached->getResultCode()); } - foreach ($result as $key => & $value) { + foreach ($result as & $value) { $value = array(); } diff --git a/src/Storage/Plugin/Serializer.php b/src/Storage/Plugin/Serializer.php index ec8c46ba8..c90d86077 100644 --- a/src/Storage/Plugin/Serializer.php +++ b/src/Storage/Plugin/Serializer.php @@ -218,7 +218,6 @@ public function onIncrementItemsPre(Event $event) } $failedKeys = $storage->setItems($keyValuePairs); - $result = array(); foreach ($failedKeys as $failedKey) { unset($keyValuePairs[$failedKey]); }