Passed
Push — master ( 48d05f...3266a4 )
by Mohammad
08:38
created
src/Objects/Rooms/Room.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -44,8 +44,9 @@
 block discarded – undo
44 44
 
45 45
     function hasMember($client)
46 46
     {
47
-        if(array_key_exists($client->id,$this->members))
48
-            return true;
47
+        if(array_key_exists($client->id,$this->members)) {
48
+                    return true;
49
+        }
49 50
 
50 51
         return false;
51 52
     }
Please login to merge, or discard this patch.
src/Traits/WebSocketMessagesManager.php 1 patch
Braces   +6 added lines, -4 removed lines patch added patch discarded remove patch
@@ -46,11 +46,13 @@
 block discarded – undo
46 46
      */
47 47
     function sendToWebSocketUser(ConnectionInterface $conn,$data)
48 48
     {
49
-        if(!is_array($data))
50
-            $data = ['msg'=>$data];
49
+        if(!is_array($data)) {
50
+                    $data = ['msg'=>$data];
51
+        }
51 52
 
52
-        if(isset($this->route) && $this->route->auth && !array_key_exists('sender',$data))
53
-            $data['sender'] = $this->getSenderData();
53
+        if(isset($this->route) && $this->route->auth && !array_key_exists('sender',$data)) {
54
+                    $data['sender'] = $this->getSenderData();
55
+        }
54 56
 
55 57
         $conn->send(json_encode($data));
56 58
     }
Please login to merge, or discard this patch.