diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2007-02-21 03:56:09 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2007-02-21 03:56:09 +0000 |
commit | 8060d89a47ff826856a13cae13b8cf0788ab6a0b (patch) | |
tree | 3616b8b6cb282385934eab7ebacec8248e2b29b3 /usr/local | |
parent | 12843a8a612cb54dd80782d4fdd81f4b7fb0806f (diff) | |
download | pfsense-8060d89a47ff826856a13cae13b8cf0788ab6a0b.zip pfsense-8060d89a47ff826856a13cae13b8cf0788ab6a0b.tar.gz |
Correct the ordering of unsetting the item and running the delete command. The delete command should be run after the unset so it can populate information correctly such as tinydns's data file.
Diffstat (limited to 'usr/local')
-rwxr-xr-x | usr/local/www/pkg.php | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/usr/local/www/pkg.php b/usr/local/www/pkg.php index bc57e55..7a48c20 100755 --- a/usr/local/www/pkg.php +++ b/usr/local/www/pkg.php @@ -77,16 +77,15 @@ if ($_GET['act'] == "del") { $a_pkg = &$config['installedpackages'][xml_safe_fieldname($pkg['name'])]['config']; if ($a_pkg[$_GET['id']]) { - if($pkg['custom_delete_php_command'] <> "") { - if($pkg['custom_php_command_before_form'] <> "") - eval($pkg['custom_php_command_before_form']); - eval($pkg['custom_delete_php_command']); - } - - unset($a_pkg[$_GET['id']]); - write_config(); - header("Location: pkg.php?xml=" . $xml); - exit; + unset($a_pkg[$_GET['id']]); + write_config(); + if($pkg['custom_delete_php_command'] <> "") { + if($pkg['custom_php_command_before_form'] <> "") + eval($pkg['custom_php_command_before_form']); + eval($pkg['custom_delete_php_command']); + } + header("Location: pkg.php?xml=" . $xml); + exit; } } |