Upgrade/Install: Deactivate Gutenberg plugin on update to 5.0.
Props mcsf. Merges [43765] to trunk. Fixes #45123. git-svn-id: https://develop.svn.wordpress.org/trunk@44125 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
afa6771c23
commit
8c5f87daf7
@ -793,6 +793,10 @@ function upgrade_all() {
|
||||
upgrade_460();
|
||||
}
|
||||
|
||||
if ( $wp_current_db_version < 43764 ) {
|
||||
upgrade_500();
|
||||
}
|
||||
|
||||
maybe_disable_link_manager();
|
||||
|
||||
maybe_disable_automattic_widgets();
|
||||
@ -2069,6 +2073,25 @@ function upgrade_460() {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes changes made in WordPress 5.0.0.
|
||||
*
|
||||
* @ignore
|
||||
* @since 5.0.0
|
||||
*
|
||||
* @global int $wp_current_db_version Current database version.
|
||||
*/
|
||||
function upgrade_500() {
|
||||
global $wp_current_db_version;
|
||||
if ( $wp_current_db_version < 43764 ) {
|
||||
// Allow bypassing Gutenberg plugin deactivation.
|
||||
if ( defined( 'GUTENBERG_USE_PLUGIN' ) && GUTENBERG_USE_PLUGIN ) {
|
||||
return;
|
||||
}
|
||||
deactivate_plugins( array( 'gutenberg/gutenberg.php' ), true );
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes network-level upgrade routines.
|
||||
*
|
||||
|
@ -20,7 +20,7 @@ $wp_version = '5.1-alpha-43677-src';
|
||||
*
|
||||
* @global int $wp_db_version
|
||||
*/
|
||||
$wp_db_version = 42836;
|
||||
$wp_db_version = 43764;
|
||||
|
||||
/**
|
||||
* Holds the TinyMCE version
|
||||
|
Loading…
Reference in New Issue
Block a user