fix: do not add the same server twice
This commit is contained in:
@@ -37,6 +37,9 @@ class Destination extends Component
|
|||||||
$this->networks = $this->networks->reject(function ($network) use ($all_networks) {
|
$this->networks = $this->networks->reject(function ($network) use ($all_networks) {
|
||||||
return $all_networks->pluck('id')->contains($network->id);
|
return $all_networks->pluck('id')->contains($network->id);
|
||||||
});
|
});
|
||||||
|
$this->networks = $this->networks->reject(function ($network) {
|
||||||
|
return $this->resource->destination->server->id == $network->server->id;
|
||||||
|
});
|
||||||
}
|
}
|
||||||
public function redeploy(int $network_id, int $server_id)
|
public function redeploy(int $network_id, int $server_id)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user