Actually remove deleted plugins from the active plugin list. This has been broken for ever. fixes #1709

git-svn-id: http://svn.automattic.com/wordpress/trunk@2932 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2005-10-05 23:19:48 +00:00
parent d0a769dd73
commit 8bf7f4c443

View File

@ -43,8 +43,11 @@ if ( !is_array($check_plugins) ) {
foreach ($check_plugins as $check_plugin) {
if (!file_exists(ABSPATH . 'wp-content/plugins/' . $check_plugin)) {
$current = get_settings('active_plugins');
unset($current[$_GET['plugin']]);
update_option('active_plugins', $current);
$key = array_search($check_plugin, $current);
if ( false !== $key && NULL !== $key ) {
unset($current[$key]);
update_option('active_plugins', $current);
}
}
}
?>