forked from Alex/Pterodactyl-Panel
Fix server transformer
Properly pass the value to wings
This commit is contained in:
parent
2561e3e8d5
commit
b351c07d34
@ -105,6 +105,7 @@ class Server extends Validable
|
||||
'swap' => 'required|numeric|min:-1',
|
||||
'io' => 'required|numeric|between:10,1000',
|
||||
'cpu' => 'required|numeric|min:0',
|
||||
'threads' => 'present|nullable|regex:/^([\d-,]+)$/',
|
||||
'oom_disabled' => 'sometimes|boolean',
|
||||
'disk' => 'required|numeric|min:0',
|
||||
'allocation_id' => 'required|bail|unique:servers|exists:allocations,id',
|
||||
@ -134,6 +135,7 @@ class Server extends Validable
|
||||
'disk' => 'integer',
|
||||
'io' => 'integer',
|
||||
'cpu' => 'integer',
|
||||
'threads' => 'string',
|
||||
'oom_disabled' => 'boolean',
|
||||
'allocation_id' => 'integer',
|
||||
'nest_id' => 'integer',
|
||||
|
@ -81,7 +81,7 @@ class ServerConfigurationStructureService
|
||||
'swap' => $server->swap,
|
||||
'io_weight' => $server->io,
|
||||
'cpu_limit' => $server->cpu,
|
||||
'cpu_threads' => $server->threads,
|
||||
'threads' => $server->threads,
|
||||
'disk_space' => $server->disk,
|
||||
],
|
||||
'service' => [
|
||||
|
@ -75,6 +75,7 @@ class ServerTransformer extends BaseTransformer
|
||||
'disk' => $server->disk,
|
||||
'io' => $server->io,
|
||||
'cpu' => $server->cpu,
|
||||
'threads' => $server->threads,
|
||||
],
|
||||
'feature_limits' => [
|
||||
'databases' => $server->database_limit,
|
||||
|
Loading…
Reference in New Issue
Block a user