Make WordPress Core

Ticket #37267: 37267-1.patch

File 37267-1.patch, 756 bytes (added by jignesh.nakrani, 5 years ago)

here is a patch to skip rendering cancel comment reply link if comments aren't threaded.

  • wp-includes/comment-template.php

     
    24762476
    24772477                comment_form_title( $args['title_reply'], $args['title_reply_to'] );
    24782478
    2479                 echo $args['cancel_reply_before'];
     2479                if ( get_option('thread_comments') ) {
    24802480
    2481                 cancel_comment_reply_link( $args['cancel_reply_link'] );
     2481                        echo $args['cancel_reply_before'];
    24822482
    2483                 echo $args['cancel_reply_after'];
     2483                        cancel_comment_reply_link( $args['cancel_reply_link'] );
    24842484
     2485                        echo $args['cancel_reply_after'];
     2486
     2487                }
     2488
    24852489                echo $args['title_reply_after'];
    24862490
    24872491                if ( get_option( 'comment_registration' ) && ! is_user_logged_in() ) :