Passed
Push — master ( f55dd4...6ac744 )
by Mohammad
13:39 queued 20s
created
src/Receiver.php 1 patch
Braces   +9 added lines, -8 removed lines patch added patch discarded remove patch
@@ -76,10 +76,11 @@  discard block
 block discarded – undo
76 76
 
77 77
             \Session::start();
78 78
 
79
-            if($this->routes[$msg->route]->auth && !\Auth::check())
80
-                $this->error($msg,$from,'Unauthenticated.');
81
-            else
82
-                $this->userAuthSocketMapper[\Auth::id()] = $from->resourceId;
79
+            if($this->routes[$msg->route]->auth && !\Auth::check()) {
80
+                            $this->error($msg,$from,'Unauthenticated.');
81
+            } else {
82
+                            $this->userAuthSocketMapper[\Auth::id()] = $from->resourceId;
83
+            }
83 84
 
84 85
             $class = $this->routes[$msg->route]->controller;
85 86
             $method = $this->routes[$msg->route]->method;
@@ -95,8 +96,7 @@  discard block
 block discarded – undo
95 96
             }
96 97
 
97 98
             $controller->$method($msg);
98
-        }
99
-        catch (WebSocketException $exception)
99
+        } catch (WebSocketException $exception)
100 100
         {
101 101
 
102 102
         }
@@ -136,8 +136,9 @@  discard block
 block discarded – undo
136 136
             $this->error($msg,$from,'You can\'t send a request without the route and the session id !');
137 137
         }
138 138
 
139
-        if(!isset($this->routes[$msg->route]))
140
-            $this->error($msg,$from,'No such route !');
139
+        if(!isset($this->routes[$msg->route])) {
140
+                    $this->error($msg,$from,'No such route !');
141
+        }
141 142
     }
142 143
 
143 144
     /**
Please login to merge, or discard this patch.