mirror of
https://github.com/WordPress/WordPress.git
synced 2025-01-02 22:48:12 +01:00
Coding Standards: Use strict comparison in wp-includes/class-walker-comment.php
.
Follow-up to [8869], [9207], [23694], [47887]. Props aristath, poena, afercia, SergeyBiryukov. See #60700. Built from https://develop.svn.wordpress.org/trunk@57850 git-svn-id: http://core.svn.wordpress.org/trunk@57351 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b5ef90af01
commit
cc416fc17b
@ -278,7 +278,7 @@ class Walker_Comment extends Walker {
|
|||||||
$commenter = wp_get_current_commenter();
|
$commenter = wp_get_current_commenter();
|
||||||
$show_pending_links = ! empty( $commenter['comment_author'] );
|
$show_pending_links = ! empty( $commenter['comment_author'] );
|
||||||
|
|
||||||
if ( $comment && '0' == $comment->comment_approved && ! $show_pending_links ) {
|
if ( $comment && '0' === $comment->comment_approved && ! $show_pending_links ) {
|
||||||
$comment_text = wp_kses( $comment_text, array() );
|
$comment_text = wp_kses( $comment_text, array() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -320,14 +320,14 @@ class Walker_Comment extends Walker {
|
|||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<div class="comment-author vcard">
|
<div class="comment-author vcard">
|
||||||
<?php
|
<?php
|
||||||
if ( 0 != $args['avatar_size'] ) {
|
if ( 0 !== $args['avatar_size'] ) {
|
||||||
echo get_avatar( $comment, $args['avatar_size'] );
|
echo get_avatar( $comment, $args['avatar_size'] );
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<?php
|
<?php
|
||||||
$comment_author = get_comment_author_link( $comment );
|
$comment_author = get_comment_author_link( $comment );
|
||||||
|
|
||||||
if ( '0' == $comment->comment_approved && ! $show_pending_links ) {
|
if ( '0' === $comment->comment_approved && ! $show_pending_links ) {
|
||||||
$comment_author = get_comment_author( $comment );
|
$comment_author = get_comment_author( $comment );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -338,7 +338,7 @@ class Walker_Comment extends Walker {
|
|||||||
);
|
);
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
<?php if ( '0' == $comment->comment_approved ) : ?>
|
<?php if ( '0' === $comment->comment_approved ) : ?>
|
||||||
<em class="comment-awaiting-moderation"><?php echo $moderation_note; ?></em>
|
<em class="comment-awaiting-moderation"><?php echo $moderation_note; ?></em>
|
||||||
<br />
|
<br />
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
@ -423,14 +423,14 @@ class Walker_Comment extends Walker {
|
|||||||
<footer class="comment-meta">
|
<footer class="comment-meta">
|
||||||
<div class="comment-author vcard">
|
<div class="comment-author vcard">
|
||||||
<?php
|
<?php
|
||||||
if ( 0 != $args['avatar_size'] ) {
|
if ( 0 !== $args['avatar_size'] ) {
|
||||||
echo get_avatar( $comment, $args['avatar_size'] );
|
echo get_avatar( $comment, $args['avatar_size'] );
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<?php
|
<?php
|
||||||
$comment_author = get_comment_author_link( $comment );
|
$comment_author = get_comment_author_link( $comment );
|
||||||
|
|
||||||
if ( '0' == $comment->comment_approved && ! $show_pending_links ) {
|
if ( '0' === $comment->comment_approved && ! $show_pending_links ) {
|
||||||
$comment_author = get_comment_author( $comment );
|
$comment_author = get_comment_author( $comment );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -460,7 +460,7 @@ class Walker_Comment extends Walker {
|
|||||||
?>
|
?>
|
||||||
</div><!-- .comment-metadata -->
|
</div><!-- .comment-metadata -->
|
||||||
|
|
||||||
<?php if ( '0' == $comment->comment_approved ) : ?>
|
<?php if ( '0' === $comment->comment_approved ) : ?>
|
||||||
<em class="comment-awaiting-moderation"><?php echo $moderation_note; ?></em>
|
<em class="comment-awaiting-moderation"><?php echo $moderation_note; ?></em>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</footer><!-- .comment-meta -->
|
</footer><!-- .comment-meta -->
|
||||||
@ -470,7 +470,7 @@ class Walker_Comment extends Walker {
|
|||||||
</div><!-- .comment-content -->
|
</div><!-- .comment-content -->
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
if ( '1' == $comment->comment_approved || $show_pending_links ) {
|
if ( '1' === $comment->comment_approved || $show_pending_links ) {
|
||||||
comment_reply_link(
|
comment_reply_link(
|
||||||
array_merge(
|
array_merge(
|
||||||
$args,
|
$args,
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '6.6-alpha-57849';
|
$wp_version = '6.6-alpha-57850';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
Loading…
Reference in New Issue
Block a user