diff --git a/wp-includes/update.php b/wp-includes/update.php index 04c8aa3ec2..bc295359bf 100644 --- a/wp-includes/update.php +++ b/wp-includes/update.php @@ -89,6 +89,8 @@ function wp_version_check( $extra_stats = array(), $force_check = false ) { $wp_install = home_url( '/' ); } + $extensions = get_loaded_extensions(); + sort( $extensions, SORT_STRING | SORT_FLAG_CASE ); $query = array( 'version' => $wp_version, 'php' => $php_version, @@ -99,8 +101,42 @@ function wp_version_check( $extra_stats = array(), $force_check = false ) { 'users' => get_user_count(), 'multisite_enabled' => $multisite_enabled, 'initial_db_version' => get_site_option( 'initial_db_version' ), + 'extensions' => array_combine( $extensions, array_map( 'phpversion', $extensions ) ), + 'platform_flags' => array( + 'os' => PHP_OS, + 'bits' => PHP_INT_SIZE === 4 ? 32 : 64, + ), + 'image_support' => array(), ); + if ( function_exists( 'gd_info' ) ) { + $gd_info = gd_info(); + // Filter to supported values. + $gd_info = array_filter( $gd_info ); + + // Add data for GD WebP and AVIF support. + $query['image_support']['gd'] = array_keys( + array_filter( + array( + 'webp' => isset( $gd_info['WebP Support'] ), + 'avif' => isset( $gd_info['AVIF Support'] ), + ) + ) + ); + } + + if ( class_exists( 'Imagick' ) ) { + // Add data for Imagick WebP and AVIF support. + $query['image_support']['imagick'] = array_keys( + array_filter( + array( + 'webp' => ! empty( Imagick::queryFormats( 'WEBP' ) ), + 'avif' => ! empty( Imagick::queryFormats( 'AVIF' ) ), + ) + ) + ); + } + /** * Filters the query arguments sent as part of the core version check. * diff --git a/wp-includes/version.php b/wp-includes/version.php index 425ef3297d..f2f32610df 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.1-alpha-53752'; +$wp_version = '6.1-alpha-53753'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.