Make WordPress Core


Ignore:
Timestamp:
08/17/2018 01:50:26 AM (8 years ago)
Author:
pento
Message:

Coding Standards: Upgrade WPCS to 1.0.0

WPCS 1.0.0 includes a bunch of new auto-fixers, which drops the number of coding standards issues across WordPress significantly. Prior to running the auto-fixers, there were 15,312 issues detected. With this commit, we now drop to 4,769 issues.

This change includes three notable additions:

  • Multiline function calls must now put each parameter on a new line.
  • Auto-formatting files is now part of the grunt precommit script.
  • Auto-fixable coding standards issues will now cause Travis failures.

Fixes #44600.

File:
1 edited

Legend:

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

    r42871 r43571  
    191191        public function display() {
    192192                wp_nonce_field( 'fetch-list-' . get_class( $this ), '_ajax_fetch_list_nonce' );
    193 ?>
     193                ?>
    194194                <div class="tablenav top themes">
    195195                        <div class="alignleft actions">
     
    220220                $themes = $this->items;
    221221                foreach ( $themes as $theme ) {
    222                                 ?>
     222                        ?>
    223223                                <div class="available-theme installable-theme">
    224224                                <?php
     
    226226                                ?>
    227227                                </div>
    228                 <?php
     228                        <?php
    229229                } // end foreach $theme_names
    230230
     
    271271                                'tab'   => 'theme-information',
    272272                                'theme' => $theme->slug,
    273                         ), self_admin_url( 'theme-install.php' )
     273                        ),
     274                        self_admin_url( 'theme-install.php' )
    274275                );
    275276
     
    280281                                'action' => 'install-theme',
    281282                                'theme'  => $theme->slug,
    282                         ), self_admin_url( 'update.php' )
     283                        ),
     284                        self_admin_url( 'update.php' )
    283285                );
    284286
     
    287289                                'action' => 'upgrade-theme',
    288290                                'theme'  => $theme->slug,
    289                         ), self_admin_url( 'update.php' )
     291                        ),
     292                        self_admin_url( 'update.php' )
    290293                );
    291294
     
    347350
    348351                <h3><?php echo $name; ?></h3>
    349                 <div class="theme-author"><?php
     352                <div class="theme-author">
     353                <?php
    350354                        /* translators: %s: theme author */
    351355                        printf( __( 'By %s' ), $author );
    352                 ?></div>
     356                ?>
     357                </div>
    353358
    354359                <div class="action-links">
     
    431436                                'action' => 'install-theme',
    432437                                'theme'  => $theme->slug,
    433                         ), self_admin_url( 'update.php' )
     438                        ),
     439                        self_admin_url( 'update.php' )
    434440                );
    435441
     
    438444                                'action' => 'upgrade-theme',
    439445                                'theme'  => $theme->slug,
    440                         ), self_admin_url( 'update.php' )
     446                        ),
     447                        self_admin_url( 'update.php' )
    441448                );
    442449
     
    473480                                break;
    474481                }
    475                         ?>
     482                ?>
    476483                        <h3 class="theme-name"><?php echo $name; ?></h3>
    477                         <span class="theme-by"><?php
     484                        <span class="theme-by">
     485                        <?php
    478486                                /* translators: %s: theme author */
    479487                                printf( __( 'By %s' ), $author );
    480                         ?></span>
     488                        ?>
     489                        </span>
    481490                        <?php if ( isset( $theme->screenshot_url ) ) : ?>
    482491                                <img class="theme-screenshot" src="<?php echo esc_url( $theme->screenshot_url ); ?>" alt="" />
Note: See TracChangeset for help on using the changeset viewer.