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/tests/phpunit/tests/auth.php

    r42343 r43571  
    235235                $key = wp_generate_password( 20, false );
    236236                $wpdb->update(
    237                         $wpdb->users, array(
     237                        $wpdb->users,
     238                        array(
    238239                                'user_activation_key' => strtotime( '-1 hour' ) . ':' . self::$wp_hasher->HashPassword( $key ),
    239                         ), array(
     240                        ),
     241                        array(
    240242                                'ID' => $this->user->ID,
    241243                        )
     
    270272                $key = wp_generate_password( 20, false );
    271273                $wpdb->update(
    272                         $wpdb->users, array(
     274                        $wpdb->users,
     275                        array(
    273276                                'user_activation_key' => strtotime( '-48 hours' ) . ':' . self::$wp_hasher->HashPassword( $key ),
    274                         ), array(
     277                        ),
     278                        array(
    275279                                'ID' => $this->user->ID,
    276280                        )
     
    305309                $key = wp_generate_password( 20, false );
    306310                $wpdb->update(
    307                         $wpdb->users, array(
     311                        $wpdb->users,
     312                        array(
    308313                                'user_activation_key' => self::$wp_hasher->HashPassword( $key ),
    309                         ), array(
     314                        ),
     315                        array(
    310316                                'ID' => $this->user->ID,
    311317                        )
     
    332338                $key = wp_generate_password( 20, false );
    333339                $wpdb->update(
    334                         $wpdb->users, array(
     340                        $wpdb->users,
     341                        array(
    335342                                'user_activation_key' => $key,
    336                         ), array(
     343                        ),
     344                        array(
    337345                                'ID' => $this->user->ID,
    338346                        )
Note: See TracChangeset for help on using the changeset viewer.