diff options
-rw-r--r-- | etc/inc/pkg-utils.inc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/etc/inc/pkg-utils.inc b/etc/inc/pkg-utils.inc index 54d8e18..50ec813 100644 --- a/etc/inc/pkg-utils.inc +++ b/etc/inc/pkg-utils.inc @@ -268,6 +268,7 @@ function sync_package($pkg_name, $sync_depends = true, $show_message = false) { require_once($include_file); } else { log_error("Could not locate {$include_file}."); + delete_package($package['name']); install_package($package['name']); } } @@ -287,6 +288,7 @@ function sync_package($pkg_name, $sync_depends = true, $show_message = false) { if(!file_exists("/usr/local/pkg/" . $item)) { file_notice($package['name'], "The {$package['name']} package is missing required dependencies and must be reinstalled.", "Packages", "/pkg_mgr_install.php?mode=reinstallpkg&pkg={$package['name']}", 1); log_error("Could not find {$item}. Reinstalling package."); + delete_package($pkg_name); install_package($pkg_name); } else { $item_config = parse_xml_config_pkg("/usr/local/pkg/" . $item, "packagegui"); |