unbound: port to plugins_interface_map()

This commit is contained in:
Franco Fichtner 2024-09-18 11:57:05 +02:00
parent 388281afaa
commit 5fe06a19ba

View File

@ -366,8 +366,6 @@ function unbound_match_interface($interface_map)
return true;
}
$interface_map = explode(',', $interface_map);
if (!empty($general['active_interface'])) {
foreach (explode(',', $general['active_interface']) as $used) {
if (in_array($used, $interface_map)) {
@ -396,6 +394,10 @@ function unbound_configure_do($verbose = false, $interface_map = null)
{
global $config;
if (!plugins_argument_map($interface_map)) {
return;
}
$mdl = new \OPNsense\Unbound\Unbound();
/* try to avoid restarting, but make sure to let it start if it is not running */