WordPress.org

Make WordPress Core

Ticket #22072: 22072.diff

File 22072.diff, 753 bytes (added by mdawaffe, 6 years ago)
  • wp-includes/link-template.php

     
    12141214                return;
    12151215
    12161216        if ( empty($post->post_title) )
    1217                 $post->post_title = $previous ? __('Previous Post') : __('Next Post');
     1217                $the_title = $previous ? __('Previous Post') : __('Next Post');
     1218        else
     1219                $the_title = $post->post_title;
    12181220
    12191221        $date = mysql2date(get_option('date_format'), $post->post_date);
    12201222
    1221         $title = str_replace('%title', $post->post_title, $title);
     1223        $title = str_replace('%title', $the_title, $title);
    12221224        $title = str_replace('%date', $date, $title);
    12231225        $title = apply_filters('the_title', $title, $post->ID);
    12241226