@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | if (is_array($config_name)) { |
| 66 | 66 | $this->config = array_merge($this->config, $config_name); |
| 67 | 67 | } else { |
| 68 | - $this->config[ $config_name ] = $value; |
|
| 68 | + $this->config[$config_name] = $value; |
|
| 69 | 69 | } |
| 70 | 70 | } |
| 71 | 71 | |
@@ -182,7 +182,7 @@ discard block |
||
| 182 | 182 | */ |
| 183 | 183 | public function driverUnwrapData(array $wrapper) |
| 184 | 184 | { |
| 185 | - return $wrapper[ self::DRIVER_DATA_WRAPPER_INDEX ]; |
|
| 185 | + return $wrapper[self::DRIVER_DATA_WRAPPER_INDEX]; |
|
| 186 | 186 | } |
| 187 | 187 | |
| 188 | 188 | /** |
@@ -191,7 +191,7 @@ discard block |
||
| 191 | 191 | */ |
| 192 | 192 | public function driverUnwrapTags(array $wrapper) |
| 193 | 193 | { |
| 194 | - return $wrapper[ self::DRIVER_TAGS_WRAPPER_INDEX ]; |
|
| 194 | + return $wrapper[self::DRIVER_TAGS_WRAPPER_INDEX]; |
|
| 195 | 195 | } |
| 196 | 196 | |
| 197 | 197 | |
@@ -201,7 +201,7 @@ discard block |
||
| 201 | 201 | */ |
| 202 | 202 | public function driverUnwrapTime(array $wrapper) |
| 203 | 203 | { |
| 204 | - return $wrapper[ self::DRIVER_TIME_WRAPPER_INDEX ]; |
|
| 204 | + return $wrapper[self::DRIVER_TIME_WRAPPER_INDEX]; |
|
| 205 | 205 | } |
| 206 | 206 | |
| 207 | 207 | /** |
@@ -255,7 +255,7 @@ discard block |
||
| 255 | 255 | foreach ($tagsItems as $tagsItem) { |
| 256 | 256 | $data = (array) $tagsItem->get(); |
| 257 | 257 | |
| 258 | - unset($data[ $item->getKey() ]); |
|
| 258 | + unset($data[$item->getKey()]); |
|
| 259 | 259 | $tagsItem->set($data); |
| 260 | 260 | |
| 261 | 261 | /** |
@@ -306,7 +306,7 @@ discard block |
||
| 306 | 306 | */ |
| 307 | 307 | public static function isValidOption($optionName, $optionValue) |
| 308 | 308 | { |
| 309 | - if(!is_string($optionName)) |
|
| 309 | + if (!is_string($optionName)) |
|
| 310 | 310 | { |
| 311 | 311 | throw new \InvalidArgumentException('$optionName must be a string'); |
| 312 | 312 | } |
@@ -71,7 +71,7 @@ discard block |
||
| 71 | 71 | /* |
| 72 | 72 | * Skip if Existing Caching in Options |
| 73 | 73 | */ |
| 74 | - if (isset($option[ 'skipExisting' ]) && $option[ 'skipExisting' ] == true && file_exists($file_path)) { |
|
| 74 | + if (isset($option['skipExisting']) && $option['skipExisting'] == true && file_exists($file_path)) { |
|
| 75 | 75 | $content = $this->readfile($file_path); |
| 76 | 76 | $old = $this->decode($content); |
| 77 | 77 | $toWrite = false; |
@@ -217,7 +217,7 @@ discard block |
||
| 217 | 217 | public static function isValidOption($optionName, $optionValue) |
| 218 | 218 | { |
| 219 | 219 | parent::isValidOption($optionName, $optionValue); |
| 220 | - switch($optionName) |
|
| 220 | + switch ($optionName) |
|
| 221 | 221 | { |
| 222 | 222 | case 'path': |
| 223 | 223 | return is_string($optionValue); |
@@ -294,11 +294,11 @@ discard block |
||
| 294 | 294 | if (strpos($subdirFile, '.') === false) { |
| 295 | 295 | $key = $subdirFile; |
| 296 | 296 | } else { |
| 297 | - $key = explode('.', $subdirFile)[ 0 ]; |
|
| 297 | + $key = explode('.', $subdirFile)[0]; |
|
| 298 | 298 | } |
| 299 | - $content[ $key ] = [ |
|
| 299 | + $content[$key] = [ |
|
| 300 | 300 | 'size' => $size, |
| 301 | - 'write_time' => (isset($object[ 'write_time' ]) ? $object[ 'write_time' ] : null), |
|
| 301 | + 'write_time' => (isset($object['write_time']) ? $object['write_time'] : null), |
|
| 302 | 302 | ]; |
| 303 | 303 | if ($object->isExpired()) { |
| 304 | 304 | @unlink($file_path); |