From: Thomas Lamprecht Date: Thu, 6 Jun 2019 06:28:41 +0000 (+0200) Subject: vlan plug: code cleanup X-Git-Url: https://git.proxmox.com/?p=pve-network.git;a=commitdiff_plain;h=83d209f5e129737189891ae6c0be48c0407baddb vlan plug: code cleanup Signed-off-by: Thomas Lamprecht --- diff --git a/PVE/Network/Network/VlanPlugin.pm b/PVE/Network/Network/VlanPlugin.pm index 063ae49..f27e217 100644 --- a/PVE/Network/Network/VlanPlugin.pm +++ b/PVE/Network/Network/VlanPlugin.pm @@ -69,7 +69,8 @@ sub generate_network_config { die "missing vlan tag" if !$tag; - my $iface = $uplinks->{$uplink}->{name} ? $uplinks->{$uplink}->{name} : "uplink$uplink"; + my $iface = $uplinks->{$uplink}->{name}; + $iface = "uplink${uplink}" if !$iface; $iface .= ".$tag"; my $config = "\n"; $config .= "auto $iface\n";