Make WordPress Core

Changeset 28593


Ignore:
Timestamp:
05/27/2014 06:42:30 PM (10 years ago)
Author:
wonderboymusic
Message:

For YouTube playlist oEmbed, we need keep BC for wp_oembed_remove_provider() by not changing the existing YouTube endpoint keys. So, rather than merging the rules, the playlist endpoints should be on their own line.

Props kovshenin.

See #28125, [28552].

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-oembed.php

    r28578 r28593  
    2828    public function __construct() {
    2929        $providers = array(
    30             '#http://(www\.)?youtube\.com/(watch|playlist).*#i'   => array( 'http://www.youtube.com/oembed',                      true  ),
    31             '#https://(www\.)?youtube\.com/(watch|playlist).*#i'  => array( 'http://www.youtube.com/oembed?scheme=https',         true  ),
     30            '#http://(www\.)?youtube\.com/watch.*#i'              => array( 'http://www.youtube.com/oembed',                      true  ),
     31            '#https://(www\.)?youtube\.com/watch.*#i'             => array( 'http://www.youtube.com/oembed?scheme=https',         true  ),
     32            '#http://(www\.)?youtube\.com/playlist.*#i'           => array( 'http://www.youtube.com/oembed',                      true  ),
     33            '#https://(www\.)?youtube\.com/playlist.*#i'          => array( 'http://www.youtube.com/oembed?scheme=https',         true  ),
    3234            '#http://youtu\.be/.*#i'                              => array( 'http://www.youtube.com/oembed',                      true  ),
    3335            '#https://youtu\.be/.*#i'                             => array( 'http://www.youtube.com/oembed?scheme=https',         true  ),
Note: See TracChangeset for help on using the changeset viewer.