Skip to content

Commit

Permalink
Block Library: Post Author: Avoid implicit dependency on post global
Browse files Browse the repository at this point in the history
  • Loading branch information
aduth committed May 6, 2020
1 parent eeba406 commit 63f66c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/block-library/src/post-author/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,8 @@ function render_block_core_post_author( $attributes, $content, $block ) {
( $attributes['showAvatar'] ? '<div class="wp-block-post-author__avatar">' . $avatar . '</div>' : '' ) .
'<div class="wp-block-post-author__content">' .
( ! empty( $byline ) ? '<p class="wp-block-post-author__byline">' . $byline . '</p>' : '' ) .
'<p class="wp-block-post-author__name">' . get_the_author_meta( 'display_name' ) . '</p>' .
( ! empty( $attributes['showBio'] ) ? '<p class="wp-block-post-author__bio">' . get_the_author_meta( 'user_description' ) . '</p>' : '' ) .
'<p class="wp-block-post-author__name">' . get_the_author_meta( 'display_name', $author_id ) . '</p>' .
( ! empty( $attributes['showBio'] ) ? '<p class="wp-block-post-author__bio">' . get_the_author_meta( 'user_description', $author_id ) . '</p>' : '' ) .
'</div>' .
'</div>';
}
Expand Down

0 comments on commit 63f66c3

Please sign in to comment.