@@ -56,7 +56,7 @@ discard block |
||
| 56 | 56 | ->limit(10) |
| 57 | 57 | ->get(); |
| 58 | 58 | |
| 59 | - return $activities->map(function ($activity) { |
|
| 59 | + return $activities->map(function($activity) { |
|
| 60 | 60 | return (object) [ |
| 61 | 61 | 'type' => $activity->activity_type, |
| 62 | 62 | 'message' => $activity->description, |
@@ -78,7 +78,7 @@ discard block |
||
| 78 | 78 | |
| 79 | 79 | return response()->json([ |
| 80 | 80 | 'success' => true, |
| 81 | - 'activities' => array_map(function ($activity) { |
|
| 81 | + 'activities' => array_map(function($activity) { |
|
| 82 | 82 | return [ |
| 83 | 83 | 'type' => $activity->type, |
| 84 | 84 | 'message' => $activity->message, |
@@ -265,7 +265,7 @@ discard block |
||
| 265 | 265 | |
| 266 | 266 | // Get number of physical cores |
| 267 | 267 | preg_match_all('/^cpu cores\s*:\s*(\d+)/m', $cpuinfo, $coresMatches); |
| 268 | - if (! empty($coresMatches[1])) { |
|
| 268 | + if (!empty($coresMatches[1])) { |
|
| 269 | 269 | $info['cores'] = (int) $coresMatches[1][0]; |
| 270 | 270 | } |
| 271 | 271 | |
@@ -275,14 +275,14 @@ discard block |
||
| 275 | 275 | |
| 276 | 276 | // Get CPU model |
| 277 | 277 | preg_match('/^model name\s*:\s*(.+)$/m', $cpuinfo, $modelMatches); |
| 278 | - if (! empty($modelMatches[1])) { |
|
| 278 | + if (!empty($modelMatches[1])) { |
|
| 279 | 279 | $info['model'] = trim($modelMatches[1]); |
| 280 | 280 | } |
| 281 | 281 | |
| 282 | 282 | // If cores is 0, try to get from physical id count |
| 283 | 283 | if ($info['cores'] === 0) { |
| 284 | 284 | preg_match_all('/^physical id\s*:\s*(\d+)/m', $cpuinfo, $physicalMatches); |
| 285 | - $uniquePhysical = ! empty($physicalMatches[1]) ? count(array_unique($physicalMatches[1])) : 1; |
|
| 285 | + $uniquePhysical = !empty($physicalMatches[1]) ? count(array_unique($physicalMatches[1])) : 1; |
|
| 286 | 286 | $info['cores'] = (int) ($info['threads'] / $uniquePhysical); |
| 287 | 287 | } |
| 288 | 288 | } |
@@ -114,7 +114,7 @@ |
||
| 114 | 114 | */ |
| 115 | 115 | private function getRoleName(?int $roleId): string |
| 116 | 116 | { |
| 117 | - if (! $roleId) { |
|
| 117 | + if (!$roleId) { |
|
| 118 | 118 | return 'None'; |
| 119 | 119 | } |
| 120 | 120 | |