WordPress.org

Make WordPress Core

Changeset 11243


Ignore:
Timestamp:
05/08/09 19:47:30 (5 years ago)
Author:
ryan
Message:

Cache empty results for adjacent post queries

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/link-template.php

    r11241 r11243  
    913913 
    914914    $result = $wpdb->get_row("SELECT p.* FROM $wpdb->posts AS p $join $where $sort"); 
     915    if ( null === $result ) 
     916        $result = ''; 
     917 
    915918    wp_cache_set($query_key, $result, 'counts'); 
    916919    return $result; 
Note: See TracChangeset for help on using the changeset viewer.