From 5f30426e51c52da87000278f1bd7251f2fc21db3 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Wed, 9 Jul 2025 18:35:31 +0000 Subject: [PATCH] Embeds: Correct error handling in `_oembed_rest_pre_serve_request()`. Since the function is supposed to output a string and only return a boolean value, this commit ensures that an error message is properly displayed, bringing consistency with a similar fragment a few lines above. Follow-up to [35436]. Props abcd95, oglekler, SergeyBiryukov. Fixes #63652. Built from https://develop.svn.wordpress.org/trunk@60443 git-svn-id: http://core.svn.wordpress.org/trunk@59779 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/embed.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/embed.php b/wp-includes/embed.php index c38a079003..6ef190d0ea 100644 --- a/wp-includes/embed.php +++ b/wp-includes/embed.php @@ -791,7 +791,7 @@ function _oembed_rest_pre_serve_request( $served, $result, $request, $server ) { // Bail if there's no XML. if ( ! $result ) { status_header( 501 ); - return get_status_header_desc( 501 ); + die( get_status_header_desc( 501 ) ); } if ( ! headers_sent() ) { diff --git a/wp-includes/version.php b/wp-includes/version.php index b0288b720a..2cd1bf8fe8 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.9-alpha-60440'; +$wp_version = '6.9-alpha-60443'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.