mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-18 02:25:05 +00:00
fix null pointer issue for https://github.com/opnsense/core/issues/105
This commit is contained in:
parent
564571c81d
commit
bc1601085f
@ -303,7 +303,10 @@ class Rules
|
||||
$interface = $zone->interface->xpath("//" . $zone->interface);
|
||||
if (count($interface) > 0) {
|
||||
$interface = $interface[0];
|
||||
$cpinterfaces[$interface->if->__toString()] = 1;
|
||||
if ($interface->if != null) {
|
||||
// check if interface exists before appending it.
|
||||
$cpinterfaces[$interface->if->__toString()] = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user