Upgrade/Install: Revert relocation of Hello Dolly plugin.
Reverts Hello Dolly changes moving the plugin to a containing folder. Removes the `upgrade_690()` function in it's entirety as the upgrade routine is no longer required. Fully reverted commits: [60666], [60670], [60716], [60725]; partially reverts [60721]. Porps johnbillion, whyisjake, SirLouen, mindctrl, afragen, jorbin, Otto42, swissspidy, welcher, davidbaumwald. See #53323. Built from https://develop.svn.wordpress.org/trunk@61006 git-svn-id: http://core.svn.wordpress.org/trunk@60342 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -153,6 +153,8 @@ function _get_plugin_data_markup_translate( $plugin_file, $plugin_data, $markup
|
||||
load_plugin_textdomain( $textdomain, false, dirname( $plugin_file ) );
|
||||
}
|
||||
}
|
||||
} elseif ( 'hello.php' === basename( $plugin_file ) ) {
|
||||
$textdomain = 'default';
|
||||
}
|
||||
if ( $textdomain ) {
|
||||
foreach ( array( 'Name', 'PluginURI', 'Description', 'Author', 'AuthorURI', 'Version' ) as $field ) {
|
||||
@@ -1006,6 +1008,10 @@ function delete_plugins( $plugins, $deprecated = '' ) {
|
||||
|
||||
$plugin_slug = dirname( $plugin_file );
|
||||
|
||||
if ( 'hello.php' === $plugin_file ) {
|
||||
$plugin_slug = 'hello-dolly';
|
||||
}
|
||||
|
||||
// Remove language files, silently.
|
||||
if ( '.' !== $plugin_slug && ! empty( $plugin_translations[ $plugin_slug ] ) ) {
|
||||
$translations = $plugin_translations[ $plugin_slug ];
|
||||
|
||||
@@ -841,8 +841,6 @@ $_old_files = array(
|
||||
'wp-includes/js/dist/undo-manager.min.js',
|
||||
'wp-includes/js/dist/fields.min.js',
|
||||
'wp-includes/js/dist/fields.js',
|
||||
// 6.9
|
||||
'wp-content/plugins/hello.php',
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -975,7 +973,6 @@ $_new_bundled_files = array(
|
||||
'themes/twentytwentythree/' => '6.1',
|
||||
'themes/twentytwentyfour/' => '6.4',
|
||||
'themes/twentytwentyfive/' => '6.7',
|
||||
'plugins/hello-dolly/' => '6.9',
|
||||
);
|
||||
|
||||
/**
|
||||
|
||||
@@ -886,10 +886,6 @@ function upgrade_all() {
|
||||
upgrade_682();
|
||||
}
|
||||
|
||||
if ( $wp_current_db_version < 60717 ) {
|
||||
upgrade_690();
|
||||
}
|
||||
|
||||
maybe_disable_link_manager();
|
||||
|
||||
maybe_disable_automattic_widgets();
|
||||
@@ -2485,31 +2481,6 @@ function upgrade_682() {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes changes made in WordPress 6.9.0.
|
||||
*
|
||||
* @ignore
|
||||
* @since 6.9.0
|
||||
*
|
||||
* @global int $wp_current_db_version The old (current) database version.
|
||||
*/
|
||||
function upgrade_690() {
|
||||
global $wp_current_db_version;
|
||||
|
||||
if ( $wp_current_db_version < 60717 ) {
|
||||
// Switch Hello Dolly from file to directory format. See #53323
|
||||
$active_plugins = (array) get_option( 'active_plugins', array() );
|
||||
$old_plugin = 'hello.php';
|
||||
$new_plugin = 'hello-dolly/hello.php';
|
||||
$key = array_search( $old_plugin, $active_plugins, true );
|
||||
|
||||
if ( $key ) {
|
||||
$active_plugins[ $key ] = $new_plugin;
|
||||
update_option( 'active_plugins', $active_plugins );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes network-level upgrade routines.
|
||||
*
|
||||
|
||||
@@ -870,6 +870,9 @@ class WP_Plugin_Dependencies {
|
||||
* @return string The plugin's slug.
|
||||
*/
|
||||
protected static function convert_to_slug( $plugin_file ) {
|
||||
if ( 'hello.php' === $plugin_file ) {
|
||||
return 'hello-dolly';
|
||||
}
|
||||
return str_contains( $plugin_file, '/' ) ? dirname( $plugin_file ) : str_replace( '.php', '', $plugin_file );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '6.9-alpha-61005';
|
||||
$wp_version = '6.9-alpha-61006';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
||||
Reference in New Issue
Block a user