summaryrefslogtreecommitdiffstats
path: root/usr/local
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2007-02-21 03:56:09 +0000
committerScott Ullrich <sullrich@pfsense.org>2007-02-21 03:56:09 +0000
commit8060d89a47ff826856a13cae13b8cf0788ab6a0b (patch)
tree3616b8b6cb282385934eab7ebacec8248e2b29b3 /usr/local
parent12843a8a612cb54dd80782d4fdd81f4b7fb0806f (diff)
downloadpfsense-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-xusr/local/www/pkg.php19
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;
}
}
OpenPOWER on IntegriCloud