@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | |
| 76 | 76 | $options = []; |
| 77 | 77 | |
| 78 | - if($this->getConfig()->getOptPrefix()){ |
|
| 78 | + if ($this->getConfig()->getOptPrefix()) { |
|
| 79 | 79 | $options['prefix'] = $this->getConfig()->getOptPrefix(); |
| 80 | 80 | } |
| 81 | 81 | |
@@ -131,7 +131,7 @@ discard block |
||
| 131 | 131 | * @see https://redis.io/commands/expire |
| 132 | 132 | */ |
| 133 | 133 | if ($ttl <= 0) { |
| 134 | - return (bool)$this->instance->expire($item->getKey(), 0); |
|
| 134 | + return (bool) $this->instance->expire($item->getKey(), 0); |
|
| 135 | 135 | } |
| 136 | 136 | |
| 137 | 137 | return $this->instance->setex($item->getKey(), $ttl, $this->encode($this->driverPreWrap($item)))->getPayload() === 'OK'; |
@@ -151,7 +151,7 @@ discard block |
||
| 151 | 151 | * Check for Cross-Driver type confusion |
| 152 | 152 | */ |
| 153 | 153 | if ($item instanceof Item) { |
| 154 | - return (bool)$this->instance->del([$item->getKey()]); |
|
| 154 | + return (bool) $this->instance->del([$item->getKey()]); |
|
| 155 | 155 | } |
| 156 | 156 | |
| 157 | 157 | throw new PhpfastcacheInvalidArgumentException('Cross-Driver type confusion detected'); |
@@ -198,7 +198,7 @@ discard block |
||
| 198 | 198 | return (new DriverStatistic()) |
| 199 | 199 | ->setData(\implode(', ', \array_keys($this->itemInstances))) |
| 200 | 200 | ->setRawData($info) |
| 201 | - ->setSize((int)$size) |
|
| 201 | + ->setSize((int) $size) |
|
| 202 | 202 | ->setInfo(\sprintf("The Redis daemon v%s is up since %s.\n For more information see RawData. \n Driver size includes the memory allocation size.", |
| 203 | 203 | $version, $date->format(\DATE_RFC2822))); |
| 204 | 204 | } |
@@ -81,7 +81,7 @@ discard block |
||
| 81 | 81 | return false; |
| 82 | 82 | } |
| 83 | 83 | |
| 84 | - if($this->getConfig()->getOptPrefix()){ |
|
| 84 | + if ($this->getConfig()->getOptPrefix()) { |
|
| 85 | 85 | $this->instance->setOption(RedisClient::OPT_PREFIX, $this->getConfig()->getOptPrefix()); |
| 86 | 86 | } |
| 87 | 87 | |
@@ -149,7 +149,7 @@ discard block |
||
| 149 | 149 | * Check for Cross-Driver type confusion |
| 150 | 150 | */ |
| 151 | 151 | if ($item instanceof Item) { |
| 152 | - return (bool)$this->instance->del($item->getKey()); |
|
| 152 | + return (bool) $this->instance->del($item->getKey()); |
|
| 153 | 153 | } |
| 154 | 154 | |
| 155 | 155 | throw new PhpfastcacheInvalidArgumentException('Cross-Driver type confusion detected'); |
@@ -181,7 +181,7 @@ discard block |
||
| 181 | 181 | return (new DriverStatistic()) |
| 182 | 182 | ->setData(\implode(', ', \array_keys($this->itemInstances))) |
| 183 | 183 | ->setRawData($info) |
| 184 | - ->setSize((int)$info['used_memory']) |
|
| 184 | + ->setSize((int) $info['used_memory']) |
|
| 185 | 185 | ->setInfo(\sprintf("The Redis daemon v%s is up since %s.\n For more information see RawData. \n Driver size includes the memory allocation size.", |
| 186 | 186 | $info['redis_version'], $date->format(\DATE_RFC2822))); |
| 187 | 187 | } |