WordPress.org

Plugin Directory

Changeset 587005


Ignore:
Timestamp:
08/17/12 22:12:11 (20 months ago)
Author:
mdawaffe
Message:

Shortcodes: Youtube:

Fix notice in youtube shortcode if $qargs['list'] is not set.

Props johnjamesjacoby.

http://wordpress.org/support/topic/plugin-jetpack-by-wordpresscom-bug-php-error-for-youtube-shortcode-embeds-in-161

File:
1 edited

Legend:

Unmodified
Added
Removed
  • jetpack/trunk/modules/shortcodes/youtube.php

    r579553 r587005  
    141141    $url = youtube_sanitize_url( $url ); 
    142142    $url = parse_url( $url ); 
     143    $id  = false; 
    143144 
    144145    if ( ! isset( $url['query'] ) ) 
     
    150151        return false; 
    151152 
    152     $id = preg_replace( '|[^_a-z0-9-]|i', '', $qargs['list'] ); 
     153    if ( isset( $qargs['list'] ) ) 
     154        $id = preg_replace( '|[^_a-z0-9-]|i', '', $qargs['list'] ); 
    153155 
    154156    if ( empty( $id ) ) 
Note: See TracChangeset for help on using the changeset viewer.