Make WordPress Core


Ignore:
Timestamp:
08/17/2018 01:50:26 AM (6 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-content/themes/twentyfifteen/inc/custom-header.php

    r42343 r43571  
    3333     */
    3434    add_theme_support(
    35         'custom-header', apply_filters(
    36             'twentyfifteen_custom_header_args', array(
     35        'custom-header',
     36        apply_filters(
     37            'twentyfifteen_custom_header_args',
     38            array(
    3739                'default-text-color' => $default_text_color,
    3840                'width'              => 954,
     
    98100        // Short header for when there is no Custom Header and Header Text is hidden.
    99101        if ( empty( $header_image ) && ! display_header_text() ) :
    100     ?>
     102            ?>
    101103        .site-header {
    102104            padding-top: 14px;
     
    135137            }
    136138        }
    137     <?php
     139            <?php
    138140        endif;
    139141
    140142        // Has a Custom Header been added?
    141143        if ( ! empty( $header_image ) ) :
    142     ?>
     144            ?>
    143145        .site-header {
    144146
     
    177179            }
    178180        }
    179     <?php
     181            <?php
    180182        endif;
    181183
    182184        // Has the text been hidden?
    183185        if ( ! display_header_text() ) :
    184     ?>
     186            ?>
    185187        .site-title,
    186188        .site-description {
     
    190192    <?php endif; ?>
    191193    </style>
    192     <?php
     194        <?php
    193195    }
    194196endif; // twentyfifteen_header_style
Note: See TracChangeset for help on using the changeset viewer.