Passed
Push — master ( c4dde7...0e7627 )
by BENOIT
01:46
created
src/Controller/SubscribeController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -114,7 +114,7 @@
 block discarded – undo
114 114
                     $topicSelector,
115 115
                     fn(string $topic, Message $message) => $this->sendIfAllowed($topic, $message, $request, $stream)
116 116
                 )
117
-                ->then(function (string $topic) use ($request) {
117
+                ->then(function(string $topic) use ($request) {
118 118
                     $clientId = $request->getAttribute('clientId');
119 119
                     $this->logger()->debug("Client {$clientId} subscribed to {$topic}");
120 120
                 });
Please login to merge, or discard this patch.
src/Controller/PublishController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -51,7 +51,7 @@
 block discarded – undo
51 51
 
52 52
         $this->transport
53 53
             ->publish($input['topic'], $message)
54
-            ->then(fn () => $this->storage->storeMessage($input['topic'], $message));
54
+            ->then(fn() => $this->storage->storeMessage($input['topic'], $message));
55 55
 
56 56
         $this->logger()->debug(
57 57
             \sprintf(
Please login to merge, or discard this patch.
src/Helpers/RedisHelper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
         /** @phpstan-ignore-next-line */
14 14
         $client->get('foo')->then(
15 15
             null,
16
-            function (\Exception $e) use ($loop, $logger) {
16
+            function(\Exception $e) use ($loop, $logger) {
17 17
                 $logger->error(\sprintf('Redis error: %s', $e->getMessage()));
18 18
                 $loop->stop();
19 19
             }
Please login to merge, or discard this patch.
src/Configuration/Configuration.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@
 block discarded – undo
44 44
 
45 45
     private function export(): array
46 46
     {
47
-        $config = \array_map(fn ($value) => \is_string($value) && '' === \trim($value) ? null : $value, $this->config);
47
+        $config = \array_map(fn($value) => \is_string($value) && '' === \trim($value) ? null : $value, $this->config);
48 48
         if (null === $config[self::JWT_KEY] && null === $config[self::PUBLISHER_JWT_KEY]) {
49 49
             throw new \InvalidArgumentException(
50 50
                 "One of \"jwt_key\" or \"publisher_jwt_key\" configuration parameter must be defined."
Please login to merge, or discard this patch.
src/Transport/Redis/RedisTransport.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
         $this->subscriber->subscribe($topicSelector);
47 47
         $this->subscriber->on(
48 48
             'message',
49
-            function (string $topic, string $payload) use ($topicSelector, $callback) {
49
+            function(string $topic, string $payload) use ($topicSelector, $callback) {
50 50
                 $this->dispatch($topic, $payload, $topicSelector, $callback);
51 51
             }
52 52
         );
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
         $this->subscriber->psubscribe($channel);
75 75
         $this->subscriber->on(
76 76
             'pmessage',
77
-            function (string $pattern, string $topic, string $payload) use ($topicSelector, $callback) {
77
+            function(string $pattern, string $topic, string $payload) use ($topicSelector, $callback) {
78 78
                 $this->dispatch($topic, $payload, $topicSelector, $callback);
79 79
             }
80 80
         );
Please login to merge, or discard this patch.
src/Transport/PHP/PHPTransport.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
     public function subscribe(string $subscribedTopic, callable $callback): PromiseInterface
30 30
     {
31
-        $this->emitter->on('message', function (string $topic, Message $message) use ($callback, $subscribedTopic) {
31
+        $this->emitter->on('message', function(string $topic, Message $message) use ($callback, $subscribedTopic) {
32 32
             if (!TopicMatcher::matchesTopicSelectors($topic, [$subscribedTopic])) {
33 33
                 return;
34 34
             }
Please login to merge, or discard this patch.
src/Metrics/Redis/RedisMetricsHandler.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -43,13 +43,13 @@
 block discarded – undo
43 43
         /** @phpstan-ignore-next-line */
44 44
         return $this->client->keys('users:*')
45 45
             ->then(
46
-                function (array $keys) {
46
+                function(array $keys) {
47 47
                     $promises = [];
48 48
                     foreach ($keys as $key) {
49 49
                         $promises[] = $this->client->get($key); /** @phpstan-ignore-line */
50 50
                     }
51 51
 
52
-                    return all($promises)->then(fn (array $results): int => \array_sum($results));
52
+                    return all($promises)->then(fn(array $results): int => \array_sum($results));
53 53
                 }
54 54
             );
55 55
     }
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
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
                 ->overrideWith($this->getInputOptions($input))
43 43
                 ->asArray();
44 44
 
45
-            $loop->futureTick(function () use ($config, $output) {
45
+            $loop->futureTick(function() use ($config, $output) {
46 46
                 $this->displayConfiguration($config, $output);
47 47
             });
48 48
 
Please login to merge, or discard this patch.
src/Command/StressSubscribersCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
         $url = $url->withQuery($qs);
64 64
         $nbSubscribers = (int) $input->getOption('subscribers');
65 65
 
66
-        $requests = function (HttpClientInterface $client, string $url) use ($nbSubscribers) {
66
+        $requests = function(HttpClientInterface $client, string $url) use ($nbSubscribers) {
67 67
             for ($i = 0; $i < $nbSubscribers; $i++) {
68 68
                 yield $client->request('GET', $url);
69 69
             }
Please login to merge, or discard this patch.