mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-19 14:53:45 +02:00
Fix bug with server default ports not being updated properly
This commit is contained in:
@@ -535,7 +535,7 @@ class ServerRepository
|
|||||||
}
|
}
|
||||||
|
|
||||||
$newPorts = true;
|
$newPorts = true;
|
||||||
$firstNewAllocation = (is_null($firstNewAllocation)) ? $model->id : $firstNewAllocation;
|
$firstNewAllocation = $firstNewAllocation ?? $model;
|
||||||
$model->update([
|
$model->update([
|
||||||
'server_id' => $server->id,
|
'server_id' => $server->id,
|
||||||
]);
|
]);
|
||||||
@@ -555,7 +555,8 @@ class ServerRepository
|
|||||||
}
|
}
|
||||||
|
|
||||||
// New Allocation, set as the default.
|
// New Allocation, set as the default.
|
||||||
$server->allocation_id = $firstNewAllocation;
|
$server->allocation_id = $firstNewAllocation->id;
|
||||||
|
$newBuild['default'] = ['ip' => $firstNewAllocation->ip, 'port' => $firstNewAllocation->port];
|
||||||
}
|
}
|
||||||
|
|
||||||
$newPorts = true;
|
$newPorts = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user