diff --git a/src/opnsense/mvc/app/models/OPNsense/IDS/Migrations/M1_0_2.php b/src/opnsense/mvc/app/models/OPNsense/IDS/Migrations/M1_0_2.php index 9e542fe35..e57b4f09d 100644 --- a/src/opnsense/mvc/app/models/OPNsense/IDS/Migrations/M1_0_2.php +++ b/src/opnsense/mvc/app/models/OPNsense/IDS/Migrations/M1_0_2.php @@ -43,7 +43,9 @@ class M1_0_2 extends BaseModelMigration { $cfgObj = Config::getInstance()->object(); $affectedUuids = []; - + if (!isset($cfgObj->OPNsense->IDS->userDefinedRules->rule)) { + return; + } foreach ($cfgObj->OPNsense->IDS->userDefinedRules->rule as $rule) { if (!empty($rule->geoip) || !empty($rule->geoip_direction)) { $affectedUuids[] = (string)$rule['uuid'];