mirror of
https://github.com/pelican-dev/panel.git
synced 2025-05-28 08:04:45 +02:00
Always limit by nodes, was like this before anyways
This commit is contained in:
parent
48f715ae69
commit
5b9e4b1729
@ -90,11 +90,10 @@ class AllocationSelectionService
|
||||
*/
|
||||
private function getRandomAllocation(array $nodes = [], array $ports = [], bool $dedicated = false): ?Allocation
|
||||
{
|
||||
$query = Allocation::query()->whereNull('server_id');
|
||||
|
||||
if (!empty($nodes)) {
|
||||
$query->whereIn('node_id', $nodes);
|
||||
}
|
||||
$query = Allocation::query()
|
||||
->whereNull('server_id')
|
||||
->whereIn('node_id', $nodes)
|
||||
;
|
||||
|
||||
if (!empty($ports)) {
|
||||
$query->where(function ($inner) use ($ports) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user