| @@ -27,9 +27,9 @@ | ||
| 27 | 27 | * |
| 28 | 28 | * @var array Provider URL structure regex. |
| 29 | 29 | */ |
| 30 | 30 | private static $provider_match_masks = [ |
| 31 | - 'youtube' => '/^.*(?:youtu\.be\/|youtube(?:-nocookie)?\.com\/(?:(?:watch)?\?(?:.*&)?vi?=|(?:embed|v|vi|user|shorts)\/))([^\?&\"\'>]+)/', | |
| 31 | + 'youtube' => '/^.*(?:youtu\.be\/|youtube(?:-nocookie)?\.com\/(?:(?:watch)?\?(?:.*&)?vi?=|(?:embed|v|vi|user)\/))([^\?&\"\'>]+)/', | |
| 32 | 32 | 'vimeo' => '/^.*vimeo\.com\/(?:[a-z]*\/)*([0-9]{6,11})[?]?.*/', |
| 33 | 33 | 'dailymotion' => '/^.*dailymotion.com\/(?:video|hub)\/([^_]+)[^#]*(#video=([^_&]+))?/', |
| 34 | 34 | 'videopress' => [ |
| 35 | 35 | '/^(?:http(?:s)?:\/\/)?videos\.files\.wordpress\.com\/([a-zA-Z\d]{8,})\//i', |
| @@ -226,10 +226,10 @@ | ||
| 226 | 226 | /** |
| 227 | 227 | * Get oembed data from the cache. |
| 228 | 228 | * if not exists in the cache it will fetch from provider and then save to the cache. |
| 229 | 229 | * |
| 230 | - * @param string $oembed_url | |
| 231 | - * @param string $cached_post_id | |
| 230 | + * @param $oembed_url | |
| 231 | + * @param $cached_post_id | |
| 232 | 232 | * |
| 233 | 233 | * @return array|null |
| 234 | 234 | */ |
| 235 | 235 | public static function get_oembed_data( $oembed_url, $cached_post_id ) { |
| @@ -257,9 +257,10 @@ | ||
| 257 | 257 | |
| 258 | 258 | /** |
| 259 | 259 | * Fetch oembed data from oembed provider. |
| 260 | 260 | * |
| 261 | - * @param string $oembed_url | |
| 261 | + * @param $oembed_url | |
| 262 | + * | |
| 262 | 263 | * @return array|null |
| 263 | 264 | */ |
| 264 | 265 | public static function fetch_oembed_data( $oembed_url ) { |
| 265 | 266 | $oembed_data = _wp_oembed_get_object()->get_data( $oembed_url ); |
| @@ -274,9 +275,9 @@ | ||
| 274 | 275 | ]; |
| 275 | 276 | } |
| 276 | 277 | |
| 277 | 278 | /** |
| 278 | - * @param string $oembed_url | |
| 279 | + * @param $oembed_url | |
| 279 | 280 | * @param null|string|int $cached_post_id |
| 280 | 281 | * |
| 281 | 282 | * @return string|null |
| 282 | 283 | */ |