diff --git a/wp-includes/embed.php b/wp-includes/embed.php index 7c533dd882..80caaee901 100644 --- a/wp-includes/embed.php +++ b/wp-includes/embed.php @@ -380,14 +380,10 @@ function get_post_embed_url( $post = null ) { function get_oembed_endpoint_url( $permalink = '', $format = 'json' ) { $url = rest_url( 'oembed/1.0/embed' ); - if ( 'json' === $format ) { - $format = false; - } - if ( '' !== $permalink ) { $url = add_query_arg( array( 'url' => urlencode( $permalink ), - 'format' => $format, + 'format' => ( 'json' !== $format ) ? $format : false, ), $url ); } diff --git a/wp-includes/version.php b/wp-includes/version.php index 9b4555ec5f..5c8e1f7319 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.7-alpha-38320'; +$wp_version = '4.7-alpha-38321'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.