diff --git a/wp-includes/version.php b/wp-includes/version.php index 0c3c5eea88..334e812231 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -13,7 +13,7 @@ * * @global string $wp_version */ -$wp_version = '5.9-alpha-51581'; +$wp_version = '5.9-alpha-51582'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. diff --git a/wp-includes/wp-db.php b/wp-includes/wp-db.php index 0d867868b8..04fa15c1ee 100644 --- a/wp-includes/wp-db.php +++ b/wp-includes/wp-db.php @@ -1627,6 +1627,13 @@ class wpdb { $client_flags = defined( 'MYSQL_CLIENT_FLAGS' ) ? MYSQL_CLIENT_FLAGS : 0; if ( $this->use_mysqli ) { + /* + * Set the MySQLi error reporting off because WordPress handles its own. + * This is due to the default value change from `MYSQLI_REPORT_OFF` + * to `MYSQLI_REPORT_ERROR|MYSQLI_REPORT_STRICT` in PHP 8.1. + */ + mysqli_report( MYSQLI_REPORT_OFF ); + $this->dbh = mysqli_init(); $host = $this->dbhost;