Make WordPress Core

Ticket #58831: 58831-align-equal-signs-for-consecutive-statements.patch

File 58831-align-equal-signs-for-consecutive-statements.patch, 4.7 KB (added by jrf, 12 months ago)
  • src/wp-admin/includes/class-wp-debug-data.php

    From bd5a9865df229a108d774ac6e67cee4ce163ebcb Mon Sep 17 00:00:00 2001
    From: jrfnl <jrfnl@users.noreply.github.com>
    Date: Wed, 19 Jul 2023 22:50:43 +0200
    Subject: [PATCH] CS: align equal signs for consecutive statements
    
    ---
     src/wp-admin/includes/class-wp-debug-data.php          | 6 +++---
     src/wp-admin/includes/class-wp-ms-sites-list-table.php | 4 ++--
     src/wp-admin/includes/class-wp-posts-list-table.php    | 2 +-
     src/wp-includes/class-wp-scripts.php                   | 2 +-
     src/wp-includes/media.php                              | 1 +
     src/wp-includes/shortcodes.php                         | 2 +-
     6 files changed, 9 insertions(+), 8 deletions(-)
    
    diff --git a/src/wp-admin/includes/class-wp-debug-data.php b/src/wp-admin/includes/class-wp-debug-data.php
    index 8590cbbdb6..550b1eea4c 100644
    a b class WP_Debug_Data { 
    845845                }
    846846
    847847                // Server time.
    848                 $date = new DateTime( 'now', new DateTimeZone( 'UTC' ) );
    849                 $info['wp-server']['fields']['current'] = array(
     848                $date                                       = new DateTime( 'now', new DateTimeZone( 'UTC' ) );
     849                $info['wp-server']['fields']['current']     = array(
    850850                        'label' => __( 'Current time' ),
    851851                        'value' => $date->format( DateTime::ATOM ),
    852852                );
    853                 $info['wp-server']['fields']['utc-time'] = array(
     853                $info['wp-server']['fields']['utc-time']    = array(
    854854                        'label' => __( 'Current UTC time' ),
    855855                        'value' => $date->format( DateTime::RFC850 ),
    856856                );
  • src/wp-admin/includes/class-wp-ms-sites-list-table.php

    diff --git a/src/wp-admin/includes/class-wp-ms-sites-list-table.php b/src/wp-admin/includes/class-wp-ms-sites-list-table.php
    index 4e54862185..a3fbca44f1 100644
    a b class WP_MS_Sites_List_Table extends WP_List_Table { 
    391391        protected function get_sortable_columns() {
    392392
    393393                if ( is_subdomain_install() ) {
    394                         $abbr = __( 'Domain' );
     394                        $abbr                  = __( 'Domain' );
    395395                        $blogname_orderby_text = __( 'Table ordered by Site Domain Name.' );
    396396                } else {
    397                         $abbr = __( 'Path' );
     397                        $abbr                  = __( 'Path' );
    398398                        $blogname_orderby_text = __( 'Table ordered by Site Path.' );
    399399                }
    400400
  • src/wp-admin/includes/class-wp-posts-list-table.php

    diff --git a/src/wp-admin/includes/class-wp-posts-list-table.php b/src/wp-admin/includes/class-wp-posts-list-table.php
    index 54bd19441d..749cbda78e 100644
    a b class WP_Posts_List_Table extends WP_List_Table { 
    765765
    766766                if ( 'page' === $post_type ) {
    767767                        $title_orderby_text = isset( $_GET['orderby'] ) ? __( 'Table ordered by Title.' ) : __( 'Table ordered by Hierarchical Menu Order and Title.' );
    768                         $sortables = array(
     768                        $sortables          = array(
    769769                                'title'    => array( 'title', false, __( 'Title' ), $title_orderby_text, 'asc' ),
    770770                                'parent'   => array( 'parent', false ),
    771771                                'comments' => array( 'comment_count', false, __( 'Comments' ), __( 'Table ordered by Comments.' ) ),
  • src/wp-includes/class-wp-scripts.php

    diff --git a/src/wp-includes/class-wp-scripts.php b/src/wp-includes/class-wp-scripts.php
    index 08aba0aa5d..cf0259c3c4 100644
    a b JS; 
    964964                        return $eligible;
    965965                }
    966966
    967                 $is_alias = (bool) ! $this->registered[ $handle ]->src;
     967                $is_alias          = (bool) ! $this->registered[ $handle ]->src;
    968968                $intended_strategy = $this->get_data( $handle, 'strategy' );
    969969
    970970                // For non-alias handles, an empty intended strategy filters all strategies.
  • src/wp-includes/media.php

    diff --git a/src/wp-includes/media.php b/src/wp-includes/media.php
    index f4d6a5a67d..db5565e385 100644
    a b function wp_get_loading_optimization_attributes( $tag_name, $attr, $context ) { 
    56205620                }
    56215621                return $loading_attributes;
    56225622        };
     5623
    56235624        // Closure to increase media count for images with certain minimum threshold, mostly used for header images.
    56245625        $maybe_increase_content_media_count = static function() use ( $attr ) {
    56255626                /** This filter is documented in wp-admin/includes/media.php */
  • src/wp-includes/shortcodes.php

    diff --git a/src/wp-includes/shortcodes.php b/src/wp-includes/shortcodes.php
    index 4d23521f44..538b6e79da 100644
    a b function do_shortcode( $content, $ignore_html = false ) { 
    222222        }
    223223
    224224        // Ensure this context is only added once if shortcodes are nested.
    225         $has_filter = has_filter( 'wp_get_attachment_image_context', '_filter_do_shortcode_context' );
     225        $has_filter   = has_filter( 'wp_get_attachment_image_context', '_filter_do_shortcode_context' );
    226226        $filter_added = false;
    227227
    228228        if ( ! $has_filter ) {