mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-03-31 18:54:29 +00:00
Embeds: In switched state, restore previous state if no post ID is found.
Fixes #40673. git-svn-id: https://develop.svn.wordpress.org/trunk@41634 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1106,6 +1106,10 @@ function wp_filter_pre_oembed_result( $result, $url, $args ) {
|
||||
$post_id = apply_filters( 'oembed_request_post_id', $post_id, $url );
|
||||
|
||||
if ( ! $post_id ) {
|
||||
if ( $switched_blog ) {
|
||||
restore_current_blog();
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user