Dashboard: Change the cache key for dashboard RSS widget; remove the unnecessary database upgrade routine.
Props iandunn, ocean90. See #40702. Built from https://develop.svn.wordpress.org/trunk@40803 git-svn-id: http://core.svn.wordpress.org/trunk@40661 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
a2788b09d5
commit
2c5e9a34b2
|
@ -981,7 +981,7 @@ function wp_dashboard_cached_rss_widget( $widget_id, $callback, $check_urls = ar
|
|||
}
|
||||
|
||||
$locale = get_user_locale();
|
||||
$cache_key = 'dash_' . md5( $widget_id . '_' . $locale );
|
||||
$cache_key = 'dash_v2_' . md5( $widget_id . '_' . $locale );
|
||||
if ( false !== ( $output = get_transient( $cache_key ) ) ) {
|
||||
echo $output;
|
||||
return true;
|
||||
|
@ -1063,7 +1063,7 @@ function wp_dashboard_rss_control( $widget_id, $form_inputs = array() ) {
|
|||
}
|
||||
update_option( 'dashboard_widget_options', $widget_options );
|
||||
$locale = get_user_locale();
|
||||
$cache_key = 'dash_' . md5( $widget_id . '_' . $locale );
|
||||
$cache_key = 'dash_v2_' . md5( $widget_id . '_' . $locale );
|
||||
delete_transient( $cache_key );
|
||||
}
|
||||
|
||||
|
|
|
@ -565,10 +565,6 @@ function upgrade_all() {
|
|||
if ( $wp_current_db_version < 37965 )
|
||||
upgrade_460();
|
||||
|
||||
if ( $wp_current_db_version < 40607 ) {
|
||||
upgrade_480();
|
||||
}
|
||||
|
||||
maybe_disable_link_manager();
|
||||
|
||||
maybe_disable_automattic_widgets();
|
||||
|
@ -1736,26 +1732,6 @@ function upgrade_460() {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes changes made in WordPress 4.8.0.
|
||||
*
|
||||
* @ignore
|
||||
* @since 4.8.0
|
||||
*
|
||||
* @global int $wp_current_db_version Current database version.
|
||||
*/
|
||||
function upgrade_480() {
|
||||
global $wp_current_db_version;
|
||||
|
||||
if ( $wp_current_db_version < 40607 ) {
|
||||
// This feature plugin was merged for #40702, so the plugin itself is no longer needed
|
||||
deactivate_plugins( array( 'nearby-wp-events/nearby-wordpress-events.php' ), true );
|
||||
|
||||
// The markup stored in this transient changed for #40702
|
||||
delete_transient( 'dash_' . md5( 'dashboard_primary' . '_' . get_locale() ) );
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes network-level upgrade routines.
|
||||
*
|
||||
|
|
|
@ -4,14 +4,14 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.8-beta1-40802';
|
||||
$wp_version = '4.8-beta1-40803';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
*
|
||||
* @global int $wp_db_version
|
||||
*/
|
||||
$wp_db_version = 40607;
|
||||
$wp_db_version = 38590;
|
||||
|
||||
/**
|
||||
* Holds the TinyMCE version
|
||||
|
|
Loading…
Reference in New Issue