mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 16:14:40 +00:00
firewall: automation: correct check order
ErrorException: Undefined array key "interface" in /usr/local/opnsense/mvc/app/controllers/OPNsense/Firewall/Api/FilterController.php:154
This commit is contained in:
parent
ab48c5afb6
commit
9c68e2eb3c
@ -151,7 +151,7 @@ class FilterController extends FilterBaseController
|
||||
$is_cat = empty($categories) || array_intersect(explode(',', $record['category'] ?? ''), $categories);
|
||||
|
||||
if (empty($interfaces)) {
|
||||
$is_if = count(explode(',', $record['interface'])) > 1 || empty($record['interface']);
|
||||
$is_if = empty($record['interface']) || count(explode(',', $record['interface'])) > 1;
|
||||
} else {
|
||||
$is_if = array_intersect(explode(',', $record['interface'] ?? ''), $interfaces);
|
||||
$is_if = $is_if || empty($record['interface']);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user