Make WordPress Core

Changeset 60096


Ignore:
Timestamp:
03/26/2025 10:28:30 AM (5 weeks ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Remove a one-time $sql variable in network_domain_check().

This allows the $wpdb::prepare() call to be picked up correctly by PHPCS.

Follow-up to [28712].

Props aristath, poena, afercia, SergeyBiryukov.
See #63168.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/network.php

    r59960 r60096  
    2020    global $wpdb;
    2121
    22     $sql = $wpdb->prepare( 'SHOW TABLES LIKE %s', $wpdb->esc_like( $wpdb->site ) );
    23     if ( $wpdb->get_var( $sql ) ) {
     22    if ( $wpdb->get_var( $wpdb->prepare( 'SHOW TABLES LIKE %s', $wpdb->esc_like( $wpdb->site ) ) ) ) {
    2423        return $wpdb->get_var( "SELECT domain FROM $wpdb->site ORDER BY id ASC LIMIT 1" );
    2524    }
     25
    2626    return false;
    2727}
Note: See TracChangeset for help on using the changeset viewer.