Avoid stomping of the $plugin variable in activate_plugin().
fixes #28102. git-svn-id: https://develop.svn.wordpress.org/trunk@28644 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
9120e6a9d7
commit
c04daa1ade
@ -538,7 +538,9 @@ function activate_plugin( $plugin, $redirect = '', $network_wide = false, $silen
|
||||
wp_redirect(add_query_arg('_error_nonce', wp_create_nonce('plugin-activation-error_' . $plugin), $redirect)); // we'll override this later if the plugin can be included without fatal error
|
||||
ob_start();
|
||||
wp_register_plugin_realpath( WP_PLUGIN_DIR . '/' . $plugin );
|
||||
$_wp_plugin_file = $plugin;
|
||||
include_once( WP_PLUGIN_DIR . '/' . $plugin );
|
||||
$plugin = $_wp_plugin_file; // Avoid stomping of the $plugin variable in a plugin.
|
||||
|
||||
if ( ! $silent ) {
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user