diff options
author | Ermal <eri@pfsense.org> | 2010-03-18 18:05:38 +0000 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2010-03-18 18:05:38 +0000 |
commit | 6b487ec69f3eae5e7d8ed0257da21febdecb7ba6 (patch) | |
tree | e8c31c2c836f4420fa91c774f484dd77992d0620 /usr/local/www/firewall_aliases_edit.php | |
parent | cf895854c2e29caeaaab966c4abccf5f074feeee (diff) | |
download | pfsense-6b487ec69f3eae5e7d8ed0257da21febdecb7ba6.zip pfsense-6b487ec69f3eae5e7d8ed0257da21febdecb7ba6.tar.gz |
Allow editing aliases. Pointyhat-to: ?!
Diffstat (limited to 'usr/local/www/firewall_aliases_edit.php')
-rwxr-xr-x | usr/local/www/firewall_aliases_edit.php | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/usr/local/www/firewall_aliases_edit.php b/usr/local/www/firewall_aliases_edit.php index b602239..3b9e635 100755 --- a/usr/local/www/firewall_aliases_edit.php +++ b/usr/local/www/firewall_aliases_edit.php @@ -143,13 +143,12 @@ if ($_POST) { $input_errors[] = "The alias name may only consist of the characters a-z, A-Z, 0-9, _."; } /* check for name conflicts */ - foreach ($a_aliases as $alias) { - if (isset($id) && ($a_aliases[$id]) && ($a_aliases[$id] === $alias)) - continue; - - if ($alias['name'] == $_POST['name']) { - $input_errors[] = "An alias with this name already exists."; - break; + if (!isset($id)) { + foreach ($a_aliases as $alias) { + if ($alias['name'] == $_POST['name']) { + $input_errors[] = "An alias with this name already exists."; + break; + } } } |