Fix irrelevant error message on plugin activation again. Props andy. Fixes #7671

git-svn-id: http://svn.automattic.com/wordpress/trunk@15744 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
scribu 2010-10-07 15:27:47 +00:00
parent c640cfb7ef
commit 307790b5ff
1 changed files with 1 additions and 1 deletions

View File

@ -483,6 +483,7 @@ function activate_plugin( $plugin, $redirect = '', $network_wide = false) {
ob_start();
include(WP_PLUGIN_DIR . '/' . $plugin);
do_action( 'activate_plugin', trim( $plugin) );
do_action( 'activate_' . trim( $plugin ) );
if ( $network_wide ) {
$current[$plugin] = time();
update_site_option( 'active_sitewide_plugins', $current );
@ -491,7 +492,6 @@ function activate_plugin( $plugin, $redirect = '', $network_wide = false) {
sort($current);
update_option('active_plugins', $current);
}
do_action( 'activate_' . trim( $plugin ) );
do_action( 'activated_plugin', trim( $plugin) );
if ( ob_get_length() > 0 ) {
$output = ob_get_clean();