WordPress.org

Make WordPress Core

Changeset 12390


Ignore:
Timestamp:
12/13/2009 01:01:30 PM (8 years ago)
Author:
westi
Message:

Fix notice on edit posts page when logged in as a user without the 'edit_others_posts' capability.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/edit.php

    r12308 r12390  
    194194
    195195if ( $user_posts ) {
    196     if ( $_GET['author'] == $current_user->ID )
     196    if ( isset( $_GET['author'] ) && ( $_GET['author'] == $current_user->ID ) )
    197197        $class = ' class="current"';
    198198    $status_links[] = "<li><a href='edit.php?author=$current_user->ID'$class>" . sprintf( _nx( 'My Posts <span class="count">(%s)</span>', 'My Posts <span class="count">(%s)</span>', $user_posts_count, 'posts' ), number_format_i18n( $user_posts_count ) ) . '</a>';
Note: See TracChangeset for help on using the changeset viewer.