diff -r 34716fd837a4 -r be944660c56a wp/wp-includes/embed.php --- a/wp/wp-includes/embed.php Tue Dec 15 15:52:01 2020 +0100 +++ b/wp/wp-includes/embed.php Wed Sep 21 18:19:35 2022 +0200 @@ -80,7 +80,7 @@ * * @since 2.9.0 * - * @param array $size { + * @param int[] $size { * Indexed array of the embed width and height in pixels. * * @type int $0 The embed width. @@ -99,8 +99,15 @@ * @see WP_oEmbed * * @param string $url The URL that should be embedded. - * @param array $args Optional. Additional arguments and parameters for retrieving embed HTML. - * Default empty. + * @param array|string $args { + * Optional. Additional arguments for retrieving embed HTML. Default empty. + * + * @type int|string $width Optional. The `maxwidth` value passed to the provider URL. + * @type int|string $height Optional. The `maxheight` value passed to the provider URL. + * @type bool $discover Optional. Determines whether to attempt to discover link tags + * at the given URL for an oEmbed provider when the provider URL + * is not found in the built-in providers list. Default true. + * } * @return string|false The embed HTML on success, false on failure. */ function wp_oembed_get( $url, $args = '' ) { @@ -204,7 +211,7 @@ * * @param callable $handler Audio embed handler callback function. */ - wp_embed_register_handler( 'audio', '#^https?://.+?\.(' . join( '|', wp_get_audio_extensions() ) . ')$#i', apply_filters( 'wp_audio_embed_handler', 'wp_embed_handler_audio' ), 9999 ); + wp_embed_register_handler( 'audio', '#^https?://.+?\.(' . implode( '|', wp_get_audio_extensions() ) . ')$#i', apply_filters( 'wp_audio_embed_handler', 'wp_embed_handler_audio' ), 9999 ); /** * Filters the video embed handler callback. @@ -213,7 +220,7 @@ * * @param callable $handler Video embed handler callback function. */ - wp_embed_register_handler( 'video', '#^https?://.+?\.(' . join( '|', wp_get_video_extensions() ) . ')$#i', apply_filters( 'wp_video_embed_handler', 'wp_embed_handler_video' ), 9999 ); + wp_embed_register_handler( 'video', '#^https?://.+?\.(' . implode( '|', wp_get_video_extensions() ) . ')$#i', apply_filters( 'wp_video_embed_handler', 'wp_embed_handler_video' ), 9999 ); } /** @@ -462,7 +469,7 @@ */ $output .= <<deleted ) || ! empty( $site->spam ) || ! empty( $site->archived ) ) { + return false; + } + if ( $site && get_current_blog_id() !== (int) $site->blog_id ) { switch_to_blog( $site->blog_id ); $switched_blog = true; @@ -842,7 +855,7 @@ if ( isset( $attrs['title'] ) ) { unset( $attrs['title'] ); - $attr_string = join( ' ', wp_list_pluck( $attrs, 'whole' ) ); + $attr_string = implode( ' ', wp_list_pluck( $attrs, 'whole' ) ); $result = str_replace( $matches[0], '