Passed
Push — master ( a1a76b...8e8b6d )
by BENOIT
06:59
created
src/Controller/PublishController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@
 block discarded – undo
54 54
 
55 55
         $this->transport
56 56
             ->publish($input['topic'], $message)
57
-            ->then(fn () => $this->storage->storeMessage($input['topic'], $message));
57
+            ->then(fn() => $this->storage->storeMessage($input['topic'], $message));
58 58
 
59 59
         $this->logger->debug(
60 60
             \sprintf(
Please login to merge, or discard this patch.
src/Hub/Hub.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -44,13 +44,13 @@  discard block
 block discarded – undo
44 44
         $localAddress = $this->config[Configuration::ADDR];
45 45
         $this->shutdownSignal = null;
46 46
         $this->metricsHandler->resetUsers($localAddress);
47
-        $this->loop->addSignal(SIGINT, function ($signal) {
47
+        $this->loop->addSignal(SIGINT, function($signal) {
48 48
             $this->stop($signal, $this->loop);
49 49
         });
50 50
         $this->loop->addPeriodicTimer(
51 51
             15,
52 52
             fn() => $this->metricsHandler->getNbUsers()->then(
53
-                function (int $nbUsers) {
53
+                function(int $nbUsers) {
54 54
                     $memory = \memory_get_usage(true) / 1024 / 1024;
55 55
                     $this->logger->debug("Users: {$nbUsers} - Memory: {$memory}MB");
56 56
                 }
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
     private function createSocketConnection(string $localAddress, LoopInterface $loop): Socket\Server
76 76
     {
77 77
         $socket = new Socket\Server($localAddress, $loop);
78
-        $socket->on('connection', function (ConnectionInterface $connection) use ($localAddress) {
78
+        $socket->on('connection', function(ConnectionInterface $connection) use ($localAddress) {
79 79
             $this->metricsHandler->incrementUsers($localAddress);
80 80
             $connection->on('close', fn() => $this->metricsHandler->decrementUsers($localAddress));
81 81
         });
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
     private function stop(int $signal, LoopInterface $loop): void
96 96
     {
97 97
         $this->shutdownSignal = $signal;
98
-        $loop->futureTick(function () use ($loop) {
98
+        $loop->futureTick(function() use ($loop) {
99 99
             $loop->stop();
100 100
         });
101 101
     }
Please login to merge, or discard this patch.
src/Transport/Redis/RedisTransportFactory.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -34,10 +34,10 @@  discard block
 block discarded – undo
34 34
         $promises = [
35 35
             'subscriber' => $factory->createClient($dsn)
36 36
                 ->then(
37
-                    function (AsynchronousClient $client) {
37
+                    function(AsynchronousClient $client) {
38 38
                         $client->on(
39 39
                             'close',
40
-                            function () {
40
+                            function() {
41 41
                                 $this->logger->error('Connection closed.');
42 42
                                 $this->loop->stop();
43 43
                             }
@@ -45,17 +45,17 @@  discard block
 block discarded – undo
45 45
 
46 46
                         return $client;
47 47
                     },
48
-                    function (\Exception $exception) {
48
+                    function(\Exception $exception) {
49 49
                         $this->loop->stop();
50 50
                         $this->logger->error($exception->getMessage());
51 51
                     }
52 52
                 ),
53 53
             'publisher' => $factory->createClient($dsn)
54 54
                 ->then(
55
-                    function (AsynchronousClient $client) {
55
+                    function(AsynchronousClient $client) {
56 56
                         $client->on(
57 57
                             'close',
58
-                            function () {
58
+                            function() {
59 59
                                 $this->logger->error('Connection closed.');
60 60
                                 $this->loop->stop();
61 61
                             }
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
 
64 64
                         return $client;
65 65
                     },
66
-                    function (\Exception $exception) {
66
+                    function(\Exception $exception) {
67 67
                         $this->loop->stop();
68 68
                         $this->logger->error($exception->getMessage());
69 69
                     }
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 
73 73
         return all($promises)
74 74
             ->then(
75
-                function (iterable $results): array {
75
+                function(iterable $results): array {
76 76
                     $clients = [];
77 77
                     foreach ($results as $key => $client) {
78 78
                         $clients[$key] = $client;
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
                 }
86 86
             )
87 87
             ->then(
88
-                fn (array $clients) => new RedisTransport($clients['subscriber'], $clients['publisher'])
88
+                fn(array $clients) => new RedisTransport($clients['subscriber'], $clients['publisher'])
89 89
             );
90 90
     }
91 91
 }
Please login to merge, or discard this patch.
src/Command/ServeCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@
 block discarded – undo
50 50
             $config = $this->configuration->overrideWith(without_nullish_values($input->getOptions()))->asArray();
51 51
             $factory = $this->factory->withConfig($config);
52 52
             $loop->futureTick(
53
-                function () use ($config, $output) {
53
+                function() use ($config, $output) {
54 54
                     $this->displayConfiguration($config, $output);
55 55
                 }
56 56
             );
Please login to merge, or discard this patch.