WordPress.org

Make WordPress Core

Changeset 14160


Ignore:
Timestamp:
04/19/10 10:50:03 (5 years ago)
Author:
dd32
Message:

Remove double-query for Author ID. Props simonwheatley. Fixes #12048

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/query.php

    r14135 r14160  
    20812081            } 
    20822082            $q['author_name'] = sanitize_title($q['author_name']); 
    2083             $q['author'] = $wpdb->get_var("SELECT ID FROM $wpdb->users WHERE user_nicename='".$q['author_name']."'"); 
    20842083            $q['author'] = get_user_by('slug', $q['author_name']); 
    20852084            if ( $q['author'] ) 
Note: See TracChangeset for help on using the changeset viewer.