WordPress.org

Make WordPress Core


Ignore:
Timestamp:
03/14/2005 01:09:49 AM (17 years ago)
Author:
ryan
Message:

Exclude admin from author list based on user_login instead of user_nickname since user_nickname can be changed. http://mosquito.wordpress.org/view.php?id=1090 Props: MC_incubus

File:
1 edited

Legend:

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

    r2241 r2444  
    157157    global $wpdb;
    158158
    159     $query = "SELECT ID, user_nickname, user_firstname, user_lastname, user_nicename from $wpdb->users " . ($exclude_admin ? "WHERE user_nickname <> 'admin' " : '') . "ORDER BY user_nickname";
     159    $query = "SELECT ID, user_nickname, user_firstname, user_lastname, user_nicename from $wpdb->users " . ($exclude_admin ? "WHERE user_login <> 'admin' " : '') . "ORDER BY user_nickname";
    160160    $authors = $wpdb->get_results($query);
    161161
Note: See TracChangeset for help on using the changeset viewer.