system: expannd to array if not an array

Allows command line use:

    # pluginctl route_reload [wan]
This commit is contained in:
Franco Fichtner 2023-03-07 12:21:30 +01:00
parent 4359fcbf11
commit dc9e22331e

View File

@ -489,8 +489,12 @@ function core_run()
];
}
function core_routing_batch($verbose, $interfaces = [])
function core_routing_batch($verbose, $interfaces = [null])
{
if (!is_array($interfaces)) {
$interfaces = [$interfaces];
}
foreach ($interfaces as $interface) {
system_routing_configure($verbose, $interface);
}