|
|
@ -180,15 +180,17 @@ class AppPlugin |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
$urlId = intval($urlId); |
|
|
|
$urlId = intval($urlId); |
|
|
|
} |
|
|
|
} |
|
|
|
api_delete_settings_params( |
|
|
|
// First call the custom uninstall to allow full access to global settings |
|
|
|
array('category = ? AND access_url = ? AND subkey = ? ' => array('Plugins', $urlId, $pluginName)) |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
$pluginPath = api_get_path(SYS_PLUGIN_PATH).$pluginName.'/uninstall.php'; |
|
|
|
$pluginPath = api_get_path(SYS_PLUGIN_PATH).$pluginName.'/uninstall.php'; |
|
|
|
if (is_file($pluginPath) && is_readable($pluginPath)) { |
|
|
|
if (is_file($pluginPath) && is_readable($pluginPath)) { |
|
|
|
// Execute the uninstall procedure. |
|
|
|
// Execute the uninstall procedure. |
|
|
|
|
|
|
|
|
|
|
|
require $pluginPath; |
|
|
|
require $pluginPath; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// Second remove all remaining global settings |
|
|
|
|
|
|
|
api_delete_settings_params( |
|
|
|
|
|
|
|
array('category = ? AND access_url = ? AND subkey = ? ' => array('Plugins', $urlId, $pluginName)) |
|
|
|
|
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|