Make WordPress Core


Ignore:
Timestamp:
07/21/2010 08:10:22 PM (14 years ago)
Author:
ryan
Message:

Use get_current_user() and get_current_user_id() instead of global current_user object. Props filofo. fixes #13934 for 3.0.1

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.0/wp-admin/includes/meta-boxes.php

    r15190 r15452  
    502502 */
    503503function post_author_meta_box($post) {
    504     global $current_user, $user_ID;
    505     $authors = get_editable_user_ids( $current_user->id, true, $post->post_type ); // TODO: ROLE SYSTEM
     504    global $user_ID;
     505    $authors = get_editable_user_ids( get_current_user_id(), true, $post->post_type ); // TODO: ROLE SYSTEM
    506506    if ( $post->post_author && !in_array($post->post_author, $authors) )
    507507        $authors[] = $post->post_author;
Note: See TracChangeset for help on using the changeset viewer.