Passed
Branch master (092af5)
by Mauro
03:02
created
Category
examples/apcu/benchmark.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
 
29 29
 $client = new Client('apcu');
30 30
 
31
-if(!$client->getRepository()->existsListInIndex('range-list')){
31
+if (!$client->getRepository()->existsListInIndex('range-list')) {
32 32
     $client->create($array, [
33 33
         'uuid' => 'range-list',
34 34
         'element-uuid' => 'id']);
Please login to merge, or discard this patch.
examples/simple-array-with-headers.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
 $client->getRepository()->flush();
36 36
 
37 37
 
38
-if(!$client->getRepository()->existsListInIndex('simple-list-with-h')){
38
+if (!$client->getRepository()->existsListInIndex('simple-list-with-h')) {
39 39
     $client->create($simpleArray, [
40 40
         'uuid' => 'simple-list-with-h',
41 41
         'element-uuid' => 'id',
Please login to merge, or discard this patch.
examples/memcached/benchmark.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
 
29 29
 $client = new Client('memcached', $config['memcached_parameters']);
30 30
 
31
-if(!$client->getRepository()->existsListInIndex('range-list')){
31
+if (!$client->getRepository()->existsListInIndex('range-list')) {
32 32
     $client->create($array, [
33 33
         'uuid' => 'range-list',
34 34
         'element-uuid' => 'id'
Please login to merge, or discard this patch.
examples/redis/benchmark.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
 
29 29
 $client = new Client('redis', $config['redis_parameters']);
30 30
 
31
-if(!$client->getRepository()->existsListInIndex('range-list')){
31
+if (!$client->getRepository()->existsListInIndex('range-list')) {
32 32
     $client->create($array, [
33 33
         'uuid' => 'range-list',
34 34
         'element-uuid' => 'id']);
Please login to merge, or discard this patch.
examples/simple-array.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
 $client = new Client('memcached', $config['memcached_parameters']);
30 30
 $client->getRepository()->flush();
31 31
 
32
-if(!$client->getRepository()->existsListInIndex('simple-list')){
32
+if (!$client->getRepository()->existsListInIndex('simple-list')) {
33 33
     $client->create($simpleArray, [
34 34
         'uuid' => 'simple-list',
35 35
         'element-uuid' => 'id',
Please login to merge, or discard this patch.
src/Command/IndexCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
         if ($index && count($index)) {
55 55
             ksort($index);
56 56
             $table = new Table($output);
57
-            $table->setHeaders(['#', 'List', 'Created on', 'Chunks', 'Chunk size', 'Headers', 'Ttl','Expires on', 'Items']);
57
+            $table->setHeaders(['#', 'List', 'Created on', 'Chunks', 'Chunk size', 'Headers', 'Ttl', 'Expires on', 'Items']);
58 58
 
59 59
             $counter = 0;
60 60
             foreach ($index as $item) {
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
     protected function implodeArrayToAString(array $input)
99 99
     {
100 100
         $output = implode(', ', array_map(
101
-            function ($v, $k) {
101
+            function($v, $k) {
102 102
                 if (is_array($v)) {
103 103
                     return $k.'[]='.implode('&'.$k.'[]=', $v);
104 104
                 } else {
Please login to merge, or discard this patch.
src/InMemoryList/Infrastructure/Persistance/MemcachedRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -150,7 +150,7 @@
 block discarded – undo
150 150
     {
151 151
         $listFirstChunk = $this->memcached->get($listUuid.self::SEPARATOR.self::CHUNK.'-1');
152 152
 
153
-        if(false === $listFirstChunk){
153
+        if (false === $listFirstChunk) {
154 154
             return false;
155 155
         }
156 156
 
Please login to merge, or discard this patch.
src/InMemoryList/Infrastructure/Persistance/RedisRepository.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
         ];
71 71
 
72 72
         // persist all in a transaction
73
-        $this->client->transaction($options, function ($tx) use ($arrayChunks, $list, $ttl, $listUuid, $items, $chunkSize) {
73
+        $this->client->transaction($options, function($tx) use ($arrayChunks, $list, $ttl, $listUuid, $items, $chunkSize) {
74 74
             foreach ($arrayChunks as $chunkNumber => $item) {
75 75
                 foreach ($item as $key => $element) {
76 76
                     $listChunkUuid = $listUuid.self::SEPARATOR.self::CHUNK.'-'.($chunkNumber + 1);
@@ -127,7 +127,7 @@  discard block
 block discarded – undo
127 127
     private function getArrayChunksKeys($listUuid, $numberOfChunks)
128 128
     {
129 129
         $arrayChunksKeys = [];
130
-        for($i=0;$i<$numberOfChunks;$i++){
130
+        for ($i = 0; $i < $numberOfChunks; $i++) {
131 131
             $arrayChunksKeys[] = $listUuid.self::SEPARATOR.self::CHUNK.'-'.($i + 1);
132 132
         }
133 133
 
@@ -352,7 +352,7 @@  discard block
 block discarded – undo
352 352
         ];
353 353
 
354 354
         // persist in a transaction
355
-        $this->client->transaction($options, function ($tx) use ($numberOfChunks, $listUuid, $elementUuid, $data) {
355
+        $this->client->transaction($options, function($tx) use ($numberOfChunks, $listUuid, $elementUuid, $data) {
356 356
             for ($i = 1; $i <= $numberOfChunks; ++$i) {
357 357
                 $chunkNumber = $listUuid.self::SEPARATOR.self::CHUNK.'-'.$i;
358 358
                 $chunk = $this->client->hgetall($chunkNumber);
Please login to merge, or discard this patch.