Changeset 6409

Show
Ignore:
Timestamp:
12/19/07 17:45:50 (9 months ago)
Author:
ryan
Message:

Allows 0 titles when sanitizing. Props mdawaffe. fixes #5293

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/wp-includes/formatting.php

    r6364 r6409  
    330330    $title = apply_filters('sanitize_title', $title); 
    331331 
    332     if (empty($title)) { 
     332    if ( '' === $title || false === $title ) 
    333333        $title = $fallback_title; 
    334     } 
    335334 
    336335    return $title; 
  • trunk/wp-includes/taxonomy.php

    r6378 r6409  
    708708        $where = $wpdb->prepare( "t.term_id = %d", $term ); 
    709709    } else { 
    710         if ( ! $term = sanitize_title($term) ) 
     710        if ( '' === $term = sanitize_title($term) ) 
    711711            return 0; 
    712712        $where = $wpdb->prepare( "t.slug = %s", $term );