Make WordPress Core

Ticket #61393: 61393.diff

File 61393.diff, 645 bytes (added by rahulsprajapati, 6 months ago)

Use user_trailingslashit to fix trailing slash issue in pagination permalink.

  • src/wp-includes/general-template.php

     
    45934593                                $page_links[] = sprintf(
    45944594                                        '<a class="page-numbers" href="%s">%s</a>',
    45954595                                        /** This filter is documented in wp-includes/general-template.php */
    4596                                         esc_url( apply_filters( 'paginate_links', $link ) ),
     4596                                        esc_url( apply_filters( 'paginate_links', user_trailingslashit( $link ) ) ),
    45974597                                        $args['before_page_number'] . number_format_i18n( $n ) . $args['after_page_number']
    45984598                                );
    45994599