From a7c3974cdc1237649d60a3e5d24d08509c91a7b6 Mon Sep 17 00:00:00 2001 From: John Blackbourn Date: Sun, 28 Aug 2016 17:50:29 +0000 Subject: [PATCH] Upgrade/Install: Don't display PHP errors during installation. If a user is installing WordPress for the first time and has set `WP_DEBUG` to true, a PHP error during installation makes for a visually jarring experience. Fixes #37358 Built from https://develop.svn.wordpress.org/trunk@38423 git-svn-id: http://core.svn.wordpress.org/trunk@38364 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/load.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/load.php b/wp-includes/load.php index 82df7bb06e..98c6d42a94 100644 --- a/wp-includes/load.php +++ b/wp-includes/load.php @@ -334,7 +334,7 @@ function wp_debug_mode() { error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR ); } - if ( defined( 'XMLRPC_REQUEST' ) || defined( 'REST_REQUEST' ) || wp_doing_ajax() ) { + if ( defined( 'XMLRPC_REQUEST' ) || defined( 'REST_REQUEST' ) || ( defined( 'WP_INSTALLING' ) && WP_INSTALLING ) || wp_doing_ajax() ) { @ini_set( 'display_errors', 0 ); } } diff --git a/wp-includes/version.php b/wp-includes/version.php index b53408dc1f..a7450d8c70 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.7-alpha-38422'; +$wp_version = '4.7-alpha-38423'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.