Coding Standards: Use strict comparison in some legacy media functions.

Follow-up to [7062], [8653], [12188].

Props aristath, poena, afercia, SergeyBiryukov.
See #62279.
Built from https://develop.svn.wordpress.org/trunk@59750


git-svn-id: http://core.svn.wordpress.org/trunk@59092 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov
2025-02-01 20:52:19 +00:00
parent fc294e0fed
commit 6e26ca2648
2 changed files with 4 additions and 4 deletions

View File

@@ -93,7 +93,7 @@ function the_media_upload_tabs() {
foreach ( $tabs as $callback => $text ) {
$class = '';
if ( $current == $callback ) {
if ( $current === $callback ) {
$class = " class='current'";
}
@@ -1172,7 +1172,7 @@ function image_align_input_fields( $post, $checked = '' ) {
foreach ( $alignments as $name => $label ) {
$name = esc_attr( $name );
$output[] = "<input type='radio' name='attachments[{$post->ID}][align]' id='image-align-{$name}-{$post->ID}' value='$name'" .
( $checked == $name ? " checked='checked'" : '' ) .
( $checked === $name ? " checked='checked'" : '' ) .
" /><label for='image-align-{$name}-{$post->ID}' class='align image-align-{$name}-label'>$label</label>";
}
@@ -1222,7 +1222,7 @@ function image_size_input_fields( $post, $check = '' ) {
$css_id = "image-size-{$size}-{$post->ID}";
// If this size is the default but that's not available, don't select it.
if ( $size == $check ) {
if ( $size === $check ) {
if ( $enabled ) {
$checked = " checked='checked'";
} else {