Simplify logic

This commit is contained in:
stilez 2016-09-25 15:01:40 +01:00 committed by GitHub
parent 6db038f768
commit 9a2d3fe1bf

View File

@ -163,14 +163,10 @@ if ($config['openvpn']["openvpn-server"] || $config['openvpn']["openvpn-client"]
}
if (!$if || !isset($iflist[$if])) {
if ("any" == $if) {
if ($if != "any" && $if != "FloatingRules" && isset($iflist['wan'])) {
$if = "wan";
} else {
$if = "FloatingRules";
} else if ("FloatingRules" != $if) {
if (isset($iflist['wan'])) {
$if = "wan";
} else {
$if = "FloatingRules";
}
}
}