Completed
Push — master ( 6d7292...93f7a5 )
by y
01:26
created
src/Reactor.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -96,8 +96,7 @@  discard block
 block discarded – undo
96 96
         if ($socket->isOpen()) {
97 97
             if ($socket instanceof WebSocketClient and $error instanceof WebSocketError) {
98 98
                 $socket->close($error->getCode(), $error->getMessage());
99
-            }
100
-            else {
99
+            } else {
101 100
                 $socket->close();
102 101
             }
103 102
         }
@@ -121,12 +120,10 @@  discard block
 block discarded – undo
121 120
             foreach ($rwe[$channel] as $id => $socket) {
122 121
                 try {
123 122
                     $socket->{$method}();
124
-                }
125
-                catch (Throwable $error) {
123
+                } catch (Throwable $error) {
126 124
                     unset($rwe[0][$id]); // prevent onReadable() if this is an OOB error.
127 125
                     $this->onError($channel, $socket, $error);
128
-                }
129
-                finally {
126
+                } finally {
130 127
                     if (!$socket->isOpen() and $this->has($socket)) {
131 128
                         $this->remove($socket);
132 129
                     }
Please login to merge, or discard this patch.