Commit 75eec3cf authored by Ad Schellevis's avatar Ad Schellevis

(config) set description when empty in legacy_config_get_interfaces

parent 2fd3a68d
......@@ -73,6 +73,7 @@ function legacy_config_get_interfaces($filters = array())
}
}
if ($iface_match) {
$iface['descr'] = !empty($iface['descr']) ? $iface['descr'] : strtoupper($ifname);
$interfaces[$ifname] = $iface;
}
}
......
......@@ -409,7 +409,7 @@ include("head.inc");
</thead>
<tbody>
<?php
foreach ($config['interfaces'] as $ifname => $iface):?>
foreach (legacy_config_get_interfaces(array("virtual" => false)) as $ifname => $iface):?>
<tr>
<td>
<strong><u><span onclick="location.href='/interfaces.php?if=<?=$ifname;?>'" style="cursor: pointer;"><?=!empty($iface['descr']) ? $iface['descr'] : strtoupper($ifname);?></span></u></strong>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment