WordPress.org

Make WordPress Core


Ignore:
Timestamp:
05/16/2020 06:40:52 PM (11 months ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Use strict comparison where static strings are involved.

This reduces the number of WordPress.PHP.StrictComparisons.LooseComparison issues in half, from 1897 to 890.

Includes minor code layout fixes for better readability.

See #49542.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-posts-list-table.php

    r47550 r47808  
    11911191                foreach ( $terms as $t ) {
    11921192                    $posts_in_term_qv = array();
    1193                     if ( 'post' != $post->post_type ) {
     1193                    if ( 'post' !== $post->post_type ) {
    11941194                        $posts_in_term_qv['post_type'] = $post->post_type;
    11951195                    }
     
    13361336        $title            = _draft_or_post_title();
    13371337
    1338         if ( $can_edit_post && 'trash' != $post->post_status ) {
     1338        if ( $can_edit_post && 'trash' !== $post->post_status ) {
    13391339            $actions['edit'] = sprintf(
    13401340                '<a href="%s" aria-label="%s">%s</a>',
     
    13961396                    );
    13971397                }
    1398             } elseif ( 'trash' != $post->post_status ) {
     1398            } elseif ( 'trash' !== $post->post_status ) {
    13991399                $actions['view'] = sprintf(
    14001400                    '<a href="%s" rel="bookmark" aria-label="%s">%s</a>',
Note: See TracChangeset for help on using the changeset viewer.