Plugins: Add file check to plugin deletions.
Merges [40169] to 4.4 branch. Built from https://develop.svn.wordpress.org/branches/4.4@40173 git-svn-id: http://core.svn.wordpress.org/branches/4.4@40112 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
3f478808ae
commit
2235a5eae7
|
@ -246,6 +246,14 @@ if ( $action ) {
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Bail on all if any paths are invalid.
|
||||||
|
// validate_file() returns truthy for invalid files
|
||||||
|
$invalid_plugin_files = array_filter( $plugins, 'validate_file' );
|
||||||
|
if ( $invalid_plugin_files ) {
|
||||||
|
wp_redirect( self_admin_url("plugins.php?plugin_status=$status&paged=$page&s=$s") );
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
|
||||||
include(ABSPATH . 'wp-admin/update.php');
|
include(ABSPATH . 'wp-admin/update.php');
|
||||||
|
|
||||||
$parent_file = 'plugins.php';
|
$parent_file = 'plugins.php';
|
||||||
|
|
Loading…
Reference in New Issue