Make WordPress Core


Ignore:
Timestamp:
11/16/2012 09:31:02 PM (14 years ago)
Author:
lancewillett
Message:

Twenty Eleven: in comments template check get_comments_number() instead of using $comments_by_type for showing a comments closed message. Props kovshenin, see #20469.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-content/themes/twentyeleven/comments.php

    r22588 r22616  
    6868         * But we only want the note on posts and pages that had comments in the first place.
    6969         */
    70         if ( ! comments_open() && ! empty( $comments_by_type['comment'] ) ) : ?>
     70        if ( ! comments_open() && get_comments_number() ) : ?>
    7171        <p class="nocomments"><?php _e( 'Comments are closed.' , 'twentyeleven' ); ?></p>
    7272        <?php endif; ?>
Note: See TracChangeset for help on using the changeset viewer.