Passed
Push — develop ( f41b30...56845b )
by Michele
48s queued 11s
created
src/Zanzara/Listener/ListenerResolver.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
                 $callbackQuery = $update->getCallbackQuery();
42 42
                 $text = $callbackQuery->getMessage() ? $callbackQuery->getMessage()->getText() : null;
43 43
                 $this->conversationManager->getConversationHandler($chatId)
44
-                    ->then(function ($handlerInfo) use ($deferred, $callbackQuery, $text, &$listeners) {
44
+                    ->then(function($handlerInfo) use ($deferred, $callbackQuery, $text, &$listeners) {
45 45
                         if (!$handlerInfo) { // if we are not in a conversation, call the listeners as usual
46 46
                             if ($text) {
47 47
                                 $this->findListenerAndPush($listeners, 'cb_query_texts', $text);
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
                             $listeners[] = new Listener($handlerInfo[0], $this->container);
54 54
                         }
55 55
                         $deferred->resolve($listeners);
56
-                    })->otherwise(function ($e) use ($deferred) {
56
+                    })->otherwise(function($e) use ($deferred) {
57 57
                         // if something goes wrong, reject the promise
58 58
                         $deferred->reject($e);
59 59
                     });
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
                 $text = $update->getMessage()->getText();
64 64
                 $chatId = $update->getEffectiveChat()->getId();
65 65
                 $this->conversationManager->getConversationHandler($chatId)
66
-                    ->then(function ($handlerInfo) use ($chatId, $text, $deferred, &$listeners) {
66
+                    ->then(function($handlerInfo) use ($chatId, $text, $deferred, &$listeners) {
67 67
                         if (!$handlerInfo) { // if we are not in a conversation, call the listeners as usual
68 68
                             $this->findListenerAndPush($listeners, 'messages', $text);
69 69
                         } elseif (!$handlerInfo[1] && $text) {
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
                             $listeners[] = new Listener($handlerInfo[0], $this->container);
84 84
                         }
85 85
                         $deferred->resolve($listeners);
86
-                    })->otherwise(function ($e) use ($deferred) {
86
+                    })->otherwise(function($e) use ($deferred) {
87 87
                         // if something goes wrong, reject the promise
88 88
                         $deferred->reject($e);
89 89
                     });
Please login to merge, or discard this patch.