Passed
Push — v7 ( 68570a...6c782e )
by Georges
01:49
created
lib/Phpfastcache/Drivers/Zendshm/Driver.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 use Phpfastcache\Core\Pool\{DriverBaseTrait, ExtendedCacheItemPoolInterface};
18 18
 use Phpfastcache\Entities\DriverStatistic;
19 19
 use Phpfastcache\Exceptions\{
20
-  PhpfastcacheInvalidArgumentException
20
+    PhpfastcacheInvalidArgumentException
21 21
 };
22 22
 use Psr\Cache\CacheItemInterface;
23 23
 
@@ -131,9 +131,9 @@  discard block
 block discarded – undo
131 131
     {
132 132
         $stats = (array)zend_shm_cache_info();
133 133
         return (new DriverStatistic())
134
-          ->setData(\implode(', ', \array_keys($this->itemInstances)))
135
-          ->setInfo(\sprintf("The Zend memory have %d item(s) in cache.\n For more information see RawData.", $stats[ 'items_total' ]))
136
-          ->setRawData($stats)
137
-          ->setSize($stats[ 'memory_total' ]);
134
+            ->setData(\implode(', ', \array_keys($this->itemInstances)))
135
+            ->setInfo(\sprintf("The Zend memory have %d item(s) in cache.\n For more information see RawData.", $stats[ 'items_total' ]))
136
+            ->setRawData($stats)
137
+            ->setSize($stats[ 'memory_total' ]);
138 138
     }
139 139
 }
140 140
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -129,11 +129,11 @@
 block discarded – undo
129 129
      */
130 130
     public function getStats(): DriverStatistic
131 131
     {
132
-        $stats = (array)zend_shm_cache_info();
132
+        $stats = (array) zend_shm_cache_info();
133 133
         return (new DriverStatistic())
134 134
           ->setData(\implode(', ', \array_keys($this->itemInstances)))
135
-          ->setInfo(\sprintf("The Zend memory have %d item(s) in cache.\n For more information see RawData.", $stats[ 'items_total' ]))
135
+          ->setInfo(\sprintf("The Zend memory have %d item(s) in cache.\n For more information see RawData.", $stats['items_total']))
136 136
           ->setRawData($stats)
137
-          ->setSize($stats[ 'memory_total' ]);
137
+          ->setSize($stats['memory_total']);
138 138
     }
139 139
 }
140 140
\ No newline at end of file
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Zendshm/Item.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
 use Phpfastcache\Core\Pool\ExtendedCacheItemPoolInterface;
19 19
 use Phpfastcache\Drivers\Zendshm\Driver as ZendSHMDriver;
20 20
 use Phpfastcache\Exceptions\{
21
-  PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
21
+    PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
22 22
 };
23 23
 
24 24
 /**
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Couchdb/Item.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
 use Phpfastcache\Core\Pool\ExtendedCacheItemPoolInterface;
21 21
 use Phpfastcache\Drivers\Couchdb\Driver as CouchdbDriver;
22 22
 use Phpfastcache\Exceptions\{
23
-  PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
23
+    PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
24 24
 };
25 25
 
26 26
 /**
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Files/Driver.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
 
18 18
 use Phpfastcache\Core\Pool\{DriverBaseTrait, ExtendedCacheItemPoolInterface, IO\IOHelperTrait};
19 19
 use Phpfastcache\Exceptions\{
20
-  PhpfastcacheInvalidArgumentException
20
+    PhpfastcacheInvalidArgumentException
21 21
 };
22 22
 use Phpfastcache\Util\Directory;
23 23
 use Psr\Cache\CacheItemInterface;
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Files/Item.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
 use Phpfastcache\Core\Pool\ExtendedCacheItemPoolInterface;
20 20
 use Phpfastcache\Drivers\Files\Driver as FilesDriver;
21 21
 use Phpfastcache\Exceptions\{
22
-  PhpfastcacheInvalidArgumentException
22
+    PhpfastcacheInvalidArgumentException
23 23
 };
24 24
 
25 25
 /**
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Redis/Item.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
 use Phpfastcache\Core\Pool\ExtendedCacheItemPoolInterface;
20 20
 use Phpfastcache\Drivers\Redis\Driver as RedisDriver;
21 21
 use Phpfastcache\Exceptions\{
22
-  PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
22
+    PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
23 23
 };
24 24
 
25 25
 /**
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Apcu/Driver.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
 use Phpfastcache\Core\Pool\{DriverBaseTrait, ExtendedCacheItemPoolInterface};
19 19
 use Phpfastcache\Entities\DriverStatistic;
20 20
 use Phpfastcache\Exceptions\{
21
-  PhpfastcacheInvalidArgumentException
21
+    PhpfastcacheInvalidArgumentException
22 22
 };
23 23
 use Psr\Cache\CacheItemInterface;
24 24
 
@@ -121,10 +121,10 @@  discard block
 block discarded – undo
121 121
         $date = (new \DateTime())->setTimestamp($stats[ 'start_time' ]);
122 122
 
123 123
         return (new DriverStatistic())
124
-          ->setData(\implode(', ', \array_keys($this->itemInstances)))
125
-          ->setInfo(\sprintf("The APCU cache is up since %s, and have %d item(s) in cache.\n For more information see RawData.", $date->format(DATE_RFC2822),
124
+            ->setData(\implode(', ', \array_keys($this->itemInstances)))
125
+            ->setInfo(\sprintf("The APCU cache is up since %s, and have %d item(s) in cache.\n For more information see RawData.", $date->format(DATE_RFC2822),
126 126
             $stats[ 'num_entries' ]))
127
-          ->setRawData($stats)
128
-          ->setSize($stats[ 'mem_size' ]);
127
+            ->setRawData($stats)
128
+            ->setSize($stats[ 'mem_size' ]);
129 129
     }
130 130
 }
131 131
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
         if ($item instanceof Item) {
62 62
             $ttl = $item->getExpirationDate()->getTimestamp() - \time();
63 63
 
64
-            return (bool)apcu_store($item->getKey(), $this->driverPreWrap($item), ($ttl > 0 ? $ttl : 0));
64
+            return (bool) apcu_store($item->getKey(), $this->driverPreWrap($item), ($ttl > 0 ? $ttl : 0));
65 65
         }
66 66
 
67 67
         throw new PhpfastcacheInvalidArgumentException('Cross-Driver type confusion detected');
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
          * Check for Cross-Driver type confusion
93 93
          */
94 94
         if ($item instanceof Item) {
95
-            return (bool)apcu_delete($item->getKey());
95
+            return (bool) apcu_delete($item->getKey());
96 96
         }
97 97
 
98 98
         throw new PhpfastcacheInvalidArgumentException('Cross-Driver type confusion detected');
@@ -117,14 +117,14 @@  discard block
 block discarded – undo
117 117
      */
118 118
     public function getStats(): DriverStatistic
119 119
     {
120
-        $stats = (array)apcu_cache_info();
121
-        $date = (new \DateTime())->setTimestamp($stats[ 'start_time' ]);
120
+        $stats = (array) apcu_cache_info();
121
+        $date = (new \DateTime())->setTimestamp($stats['start_time']);
122 122
 
123 123
         return (new DriverStatistic())
124 124
           ->setData(\implode(', ', \array_keys($this->itemInstances)))
125 125
           ->setInfo(\sprintf("The APCU cache is up since %s, and have %d item(s) in cache.\n For more information see RawData.", $date->format(DATE_RFC2822),
126
-            $stats[ 'num_entries' ]))
126
+            $stats['num_entries']))
127 127
           ->setRawData($stats)
128
-          ->setSize($stats[ 'mem_size' ]);
128
+          ->setSize($stats['mem_size']);
129 129
     }
130 130
 }
131 131
\ No newline at end of file
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Apcu/Item.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
 use Phpfastcache\Core\Pool\ExtendedCacheItemPoolInterface;
20 20
 use Phpfastcache\Drivers\Apcu\Driver as ApcuDriver;
21 21
 use Phpfastcache\Exceptions\{
22
-  PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
22
+    PhpfastcacheInvalidArgumentException, PhpfastcacheInvalidArgumentTypeException
23 23
 };
24 24
 
25 25
 /**
Please login to merge, or discard this patch.
lib/Phpfastcache/Drivers/Zenddisk/Driver.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 use Phpfastcache\Core\Pool\{DriverBaseTrait, ExtendedCacheItemPoolInterface};
18 18
 use Phpfastcache\Entities\DriverStatistic;
19 19
 use Phpfastcache\Exceptions\{
20
-  PhpfastcacheInvalidArgumentException
20
+    PhpfastcacheInvalidArgumentException
21 21
 };
22 22
 use Psr\Cache\CacheItemInterface;
23 23
 
@@ -131,9 +131,9 @@  discard block
 block discarded – undo
131 131
     {
132 132
         $stat = new DriverStatistic();
133 133
         $stat->setInfo('[ZendDisk] A void info string')
134
-          ->setSize(0)
135
-          ->setData(\implode(', ', \array_keys($this->itemInstances)))
136
-          ->setRawData(false);
134
+            ->setSize(0)
135
+            ->setData(\implode(', ', \array_keys($this->itemInstances)))
136
+            ->setRawData(false);
137 137
 
138 138
         return $stat;
139 139
     }
Please login to merge, or discard this patch.