Make WordPress Core

Changeset 11471


Ignore:
Timestamp:
05/27/2009 09:51:25 PM (16 years ago)
Author:
westi
Message:

Check to see if we have an author before displaying it. See #9948.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/default-widgets.php

    r11450 r11471  
    824824        if ( $show_author ) {
    825825            $author = $item->get_author();
    826             $author = $author->get_name();
    827             $author = ' <cite>' . esc_html( strip_tags( $author ) ) . '</cite>';
     826            if ( is_object($author) ) {
     827                $author = $author->get_name();
     828                $author = ' <cite>' . esc_html( strip_tags( $author ) ) . '</cite>';
     829            }
    828830        }
    829831
Note: See TracChangeset for help on using the changeset viewer.