After [33961], pass $comment to get_comment_link() where possible to avoid extra cache/db lookups.

See #33638.


git-svn-id: https://develop.svn.wordpress.org/trunk@34042 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Scott Taylor
2015-09-11 06:20:56 +00:00
parent 4a6a7edf55
commit 5cce4a3262
7 changed files with 11 additions and 11 deletions
+2 -2
View File
@@ -69,7 +69,7 @@ if ( !defined('ABSPATH') )
<div id="minor-publishing-actions">
<div id="preview-action">
<a class="preview button" href="<?php echo get_comment_link(); ?>" target="_blank"><?php _e('View Comment'); ?></a>
<a class="preview button" href="<?php echo get_comment_link( $comment ); ?>" target="_blank"><?php _e('View Comment'); ?></a>
</div>
<div class="clear"></div>
</div>
@@ -120,7 +120,7 @@ if ( current_user_can( 'edit_post', $post_id ) ) {
if ( $comment->comment_parent ) :
$parent = get_comment( $comment->comment_parent );
if ( $parent ) :
$parent_link = esc_url( get_comment_link( $comment->comment_parent ) );
$parent_link = esc_url( get_comment_link( $comment ) );
$name = get_comment_author( $parent );
?>
<div class="misc-pub-section misc-pub-reply-to">