Passed
Push — develop ( 88a689...418f52 )
by Nikita
14:41
created
app/Http/Controllers/GdaemonAPI/ServersController.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@
 block discarded – undo
36 36
      */
37 37
     public function index(DedicatedServer $dedicatedServer)
38 38
     {
39
-        return QueryBuilder::for(Server::where('ds_id', '=', $dedicatedServer->id))
39
+        return QueryBuilder::for (Server::where('ds_id', '=', $dedicatedServer->id))
40 40
             ->allowedFilters('id')
41 41
             ->get();
42 42
     }
Please login to merge, or discard this patch.
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,9 +36,10 @@
 block discarded – undo
36 36
      */
37 37
     public function index(DedicatedServer $dedicatedServer)
38 38
     {
39
-        return QueryBuilder::for(Server::where('ds_id', '=', $dedicatedServer->id))
40
-            ->allowedFilters('id')
39
+        return QueryBuilder::for(Server::where('ds_id', '=', $dedicatedServer->id)) {
40
+                    ->allowedFilters('id')
41 41
             ->get();
42
+        }
42 43
     }
43 44
 
44 45
     /**
Please login to merge, or discard this patch.
app/Repositories/ServerRepository.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
         }
71 71
 
72 72
         if (empty($attributes['rcon'])) {
73
-             $attributes['rcon'] = Str::random(self::DEFAULT_RCON_PASSWORD_LENGTH);
73
+                $attributes['rcon'] = Str::random(self::DEFAULT_RCON_PASSWORD_LENGTH);
74 74
         }
75 75
 
76 76
         $dedicatedServer = DedicatedServer::findOrFail($attributes['ds_id']);
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
 
64 64
         $addInstallTask = false;
65 65
         if (isset($attributes['install'])) {
66
-            $attributes['installed'] = ! $attributes['install'];
66
+            $attributes['installed'] = !$attributes['install'];
67 67
             $addInstallTask = true;
68 68
 
69 69
             unset($attributes['install']);
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
     {
180 180
         return $this->model->select(['id', 'name', 'server_ip', 'server_port', 'game_id', 'game_mod_id'])
181 181
             ->with(['game' => function($query) {
182
-                $query->select('code','name');
182
+                $query->select('code', 'name');
183 183
             }])
184 184
             ->where('name', 'LIKE', '%' . $query . '%')
185 185
             ->get();
@@ -191,9 +191,9 @@  discard block
 block discarded – undo
191 191
      */
192 192
     public function update(Server $server, array $attributes)
193 193
     {
194
-        $attributes['enabled'] = (bool)array_key_exists('enabled', $attributes);
195
-        $attributes['blocked'] = (bool)array_key_exists('blocked', $attributes);
196
-        $attributes['installed'] = (bool)array_key_exists('installed', $attributes);
194
+        $attributes['enabled'] = (bool) array_key_exists('enabled', $attributes);
195
+        $attributes['blocked'] = (bool) array_key_exists('blocked', $attributes);
196
+        $attributes['installed'] = (bool) array_key_exists('installed', $attributes);
197 197
 
198 198
         if (isset($attributes['ds_id'])) {
199 199
             $server->ds_id = $attributes['ds_id'];
Please login to merge, or discard this patch.