Make WordPress Core


Ignore:
Timestamp:
02/09/2020 04:52:28 PM (7 years ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Use Yoda conditions where appropriate.

See #49222.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class.wp-scripts.php

    r47170 r47219  
    476476         */
    477477        public function localize( $handle, $object_name, $l10n ) {
    478                 if ( $handle === 'jquery' ) {
     478                if ( 'jquery' === $handle ) {
    479479                        $handle = 'jquery-core';
    480480                }
     
    522522         */
    523523        public function set_group( $handle, $recursion, $group = false ) {
    524                 if ( isset( $this->registered[ $handle ]->args ) && $this->registered[ $handle ]->args === 1 ) {
     524                if ( isset( $this->registered[ $handle ]->args ) && 1 === $this->registered[ $handle ]->args ) {
    525525                        $grp = 1;
    526526                } else {
Note: See TracChangeset for help on using the changeset viewer.