mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
Multisite: Switch to a usermeta key for email confirmation.
To prevent inconsistent data across sites in a network the new email address is now stored in usermeta. Adds visual feedback for the case when an update has failed. All existing options will be removed on a database upgrade. Props MikeHansenMe, kovshenin, jeremyfelt, ocean90. Fixes #23358. git-svn-id: https://develop.svn.wordpress.org/trunk@36679 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1668,12 +1668,20 @@ function upgrade_440() {
|
||||
* @ignore
|
||||
* @since 4.5.0
|
||||
*
|
||||
* @global int $wp_current_db_version
|
||||
* @global int $wp_current_db_version
|
||||
* @global wpdb $wpdb
|
||||
*/
|
||||
function upgrade_450() {
|
||||
global $wp_current_db_version;
|
||||
if ( $wp_current_db_version < 36180 )
|
||||
global $wp_current_db_version, $wpdb;
|
||||
|
||||
if ( $wp_current_db_version < 36180 ) {
|
||||
wp_clear_scheduled_hook( 'wp_maybe_auto_update' );
|
||||
}
|
||||
|
||||
// Remove unused email confirmation options, moved to usermeta.
|
||||
if ( $wp_current_db_version < 36679 && is_multisite() ) {
|
||||
$wpdb->query( "DELETE FROM $wpdb->options WHERE option_name REGEXP '^[0-9]+_new_email$'" );
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user