mirror of
https://github.com/opnsense/plugins.git
synced 2026-05-28 04:34:15 -04:00
update config check to handle the default being true
This commit is contained in:
parent
f733359b01
commit
2bd53550ae
1 changed files with 1 additions and 1 deletions
|
|
@ -102,7 +102,7 @@ class ServiceController extends ApiMutableServiceControllerBase
|
|||
$config = Config::getInstance()->toArray();
|
||||
$backend = new Backend();
|
||||
|
||||
if (empty($config['OPNsense']['vnstat']['general']['separate_stats'])) {
|
||||
if (isset($config['OPNsense']['vnstat']['general']['separate_stats']) && !$config['OPNsense']['vnstat']['general']['separate_stats']) {
|
||||
// Separate stats are not wanted, just get totals - that's the default in vnstat itself,
|
||||
// no need to specify anything here.
|
||||
$response = $backend->configdpRun("vnstat", [ $type ]);
|
||||
|
|
|
|||
Loading…
Reference in a new issue