mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-14 00:24:40 +00:00
move skip_rules_gw_down feature to rule processing
This commit is contained in:
parent
b4553f0454
commit
1a3cd61dee
@ -313,6 +313,11 @@ class FilterRule
|
||||
if (!empty($interface) && empty($this->interfaceMapping[$interface]['if'])) {
|
||||
$tmp['disabled'] = true;
|
||||
}
|
||||
// disable rules when gateway is down and skip_rules_gw_down is set
|
||||
if (!empty($tmp['skip_rules_gw_down']) && !empty($tmp['gateway']) &&
|
||||
empty($this->gatewayMapping[$tmp['gateway']])) {
|
||||
$tmp['disabled'] = true;
|
||||
}
|
||||
if (!isset($tmp['quick'])) {
|
||||
// all rules are quick by default except floating
|
||||
$tmp['quick'] = !isset($rule['floating']) ? true : false;
|
||||
|
||||
@ -51,6 +51,9 @@ class Plugin
|
||||
if (!empty(Config::getInstance()->object()->system->disablereplyto)) {
|
||||
$this->systemDefaults['disablereplyto'] = true;
|
||||
}
|
||||
if (!empty(Config::getInstance()->object()->system->skip_rules_gw_down)) {
|
||||
$this->systemDefaults['skip_rules_gw_down'] = true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user