Add admin email verification screen. Shown every six months after an admin has logged in.

Also includes WPCS fixes for wp-login.php.

Props andraganescu, boemedia, lessbloat, azaozz.
See #46349.

git-svn-id: https://develop.svn.wordpress.org/trunk@45757 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz
2019-08-07 00:03:39 +00:00
parent bab0d4ee9b
commit 296d8646e7
5 changed files with 580 additions and 242 deletions
+17
View File
@@ -815,6 +815,10 @@ function upgrade_all() {
upgrade_510();
}
if ( $wp_current_db_version < 45744 ) {
upgrade_530();
}
maybe_disable_link_manager();
maybe_disable_automattic_widgets();
@@ -2114,6 +2118,19 @@ function upgrade_510() {
delete_site_option( 'upgrade_500_was_gutenberg_active' );
}
/**
* Executes changes made in WordPress 5.3.0.
*
* @ignore
* @since 5.3.0
*/
function upgrade_530() {
// Do `add_option()` rather than overwriting with `update_option()` as this may run
// after an admin was redirected to the email verification screen,
// and the option was updated.
add_option( 'admin_email_lifespan', 0 );
}
/**
* Executes network-level upgrade routines.
*