Commit 8405ee77 authored by Ad Schellevis's avatar Ad Schellevis

legacy_interface_stats using the wrong interface name. reference...

legacy_interface_stats using the wrong interface name. reference https://github.com/opnsense/core/issues/1014
parent 8346e8e3
......@@ -169,7 +169,7 @@ function legacy_interface_stats($ifs=null)
$current_interface = "";
foreach ($out as $line) {
if (strpos($line, 'Interface') === 0) {
$current_interface = explode(')', explode('(', $line)[1])[0];
$current_interface = explode('(', explode(' ', $line)[1])[0];
$stats[$current_interface] = array();
} elseif ($current_interface != "") {
$stat = explode(':', $line);
......
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