Completed
Push — master ( 9eab6b...93ca92 )
by Kamil
10s
created
src/Redis/Command/Compose/ApiSetSortedTrait.php 1 patch
Braces   +8 added lines, -4 removed lines patch added patch discarded remove patch
@@ -22,8 +22,10 @@  discard block
 block discarded – undo
22 22
     {
23 23
         $command = Enum::ZADD;
24 24
         $args = array_merge([$key], $options);
25
-        if (!empty($scoreMembers)) {
26
-            foreach ($scoreMembers as $score => $member) {
25
+        if (!empty($scoreMembers))
26
+        {
27
+            foreach ($scoreMembers as $score => $member)
28
+            {
27 29
                 $args[] = (float) $score;
28 30
                 $args[] = $member;
29 31
             }
@@ -101,12 +103,14 @@  discard block
 block discarded – undo
101 103
     {
102 104
         $command = Enum::ZRANGE;
103 105
         $args = [$key, $star, $stop];
104
-        if ($withScores) {
106
+        if ($withScores)
107
+        {
105 108
             $args[] = 'WITHSCORES';
106 109
             return $this->dispatch(Builder::build($command, $args))->then(function ($value) {
107 110
                 $len = count($value);
108 111
                 $ret = [];
109
-                for ($i=0; $i<$len; $i+=2) {
112
+                for ($i=0; $i<$len; $i+=2)
113
+                {
110 114
                     $ret[$value[$i]] = $value[$i+1];
111 115
                 }
112 116
                 return $ret;
Please login to merge, or discard this patch.
src/Redis/Command/Compose/ApiKeyValTrait.php 1 patch
Braces   +10 added lines, -5 removed lines patch added patch discarded remove patch
@@ -47,7 +47,8 @@  discard block
 block discarded – undo
47 47
         $command = Enum::BITFIELD;
48 48
         $subCommand = strtoupper($subCommand);
49 49
         //TODO: control flow improvement
50
-        switch ($subCommand) {
50
+        switch ($subCommand)
51
+        {
51 52
             case 'GET' : {
52 53
                 @list ($type, $offset) = $param;
53 54
                 $args = [$key, $subCommand, $type, $offset];
@@ -304,8 +305,10 @@  discard block
 block discarded – undo
304 305
     {
305 306
         $command = Enum::MSET;
306 307
         $args = [];
307
-        if (!empty($kvMap)) {
308
-            foreach ($kvMap as $key => $val) {
308
+        if (!empty($kvMap))
309
+        {
310
+            foreach ($kvMap as $key => $val)
311
+            {
309 312
                 $args[] = $key;
310 313
                 $args[] = $val;
311 314
             }
@@ -322,8 +325,10 @@  discard block
 block discarded – undo
322 325
     {
323 326
         $command = Enum::MSETNX;
324 327
         $args = [];
325
-        if (!empty($kvMap)) {
326
-            foreach ($kvMap as $key => $val) {
328
+        if (!empty($kvMap))
329
+        {
330
+            foreach ($kvMap as $key => $val)
331
+            {
327 332
                 $args[] = $key;
328 333
                 $args[] = $val;
329 334
             }
Please login to merge, or discard this patch.