Completed
Pull Request — master (#3)
by
unknown
32:13
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
@@ -45,7 +45,8 @@  discard block
 block discarded – undo
45 45
     public function bitField($key, $subCommand = null, ...$param)
46 46
     {
47 47
         $command = Enum::BITFIELD;
48
-        switch ($subCommand = strtoupper($subCommand)) {
48
+        switch ($subCommand = strtoupper($subCommand))
49
+        {
49 50
             case 'GET' : {
50 51
                 list ($type, $offset) = $param;
51 52
                 $args = [$subCommand, $type, $offset];
@@ -303,8 +304,10 @@  discard block
 block discarded – undo
303 304
     {
304 305
         $command = Enum::MSET;
305 306
         $args = [];
306
-        if (!empty($kvMap)) {
307
-            foreach ($kvMap as $key => $val) {
307
+        if (!empty($kvMap))
308
+        {
309
+            foreach ($kvMap as $key => $val)
310
+            {
308 311
                 $args[] = $key;
309 312
                 $args[] = $val;
310 313
             }
@@ -321,8 +324,10 @@  discard block
 block discarded – undo
321 324
     {
322 325
         $command = Enum::MSETNX;
323 326
         $args = [];
324
-        if (!empty($kvMap)) {
325
-            foreach ($kvMap as $key => $val) {
327
+        if (!empty($kvMap))
328
+        {
329
+            foreach ($kvMap as $key => $val)
330
+            {
326 331
                 $args[] = $key;
327 332
                 $args[] = $val;
328 333
             }
Please login to merge, or discard this patch.