Making WordPress.org

Ticket #5568: 5568.diff

File 5568.diff, 1.5 KB (added by Ipstenu, 4 years ago)
  • trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/inc/template-tags.php

     
    107107function the_author_byline( $post = null ) {
    108108        $post = get_post( $post );
    109109
    110         $url    = get_post_meta( $post->ID, 'header_author_uri', true );
    111         $author = strip_tags( get_post_meta( $post->ID, 'header_author', true ) ) ?: get_the_author();
    112         $author = $url ? '<a class="url fn n" rel="nofollow" href="' . esc_url( $url ) . '">' . $author . '</a>' : $author;
     110        $committers = Tools::get_plugin_committers( $post->post_name );
    113111
    114         /* translators: post author. */
    115         printf( esc_html_x( 'By %s', 'post author', 'wporg-plugins' ), '<span class="author vcard">' . wp_kses_post( $author ) . '</span>' );
     112        if ( $committers ) {
     113                $url    = get_post_meta( $post->ID, 'header_author_uri', true );
     114                $author = strip_tags( get_post_meta( $post->ID, 'header_author', true ) ) ?: get_the_author();
     115                $author = $url ? '<a class="url fn n" rel="nofollow" href="' . esc_url( $url ) . '">' . $author . '</a>' : $author;
     116
     117                /* translators: post author. */
     118                printf( esc_html_x( 'By %s', 'post author', 'wporg-plugins' ), '<span class="author vcard">' . wp_kses_post( $author ) . '</span>' );
     119        }
    116120}
    117121
    118122/**