Make WordPress Core


Ignore:
Timestamp:
01/05/2026 06:02:34 AM (4 months ago)
Author:
westonruter
Message:

Code Modernization: Formatting: Use null coalescing operator instead of isset() ternaries.

Developed as a subset of https://github.com/WordPress/wordpress-develop/pull/10654
Initially developed in https://github.com/WordPress/wordpress-develop/pull/4886

Follow-up to [61435], [61434], [61403], [61433], [61432], [61431], [61430], [61429], [61424], [61404], [61403].

Props costdev, westonruter.
See #58874, #63430.

File:
1 edited

Legend:

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

    r61051 r61436  
    30343034    $upload_info = wp_upload_dir( null, false );
    30353035    $parsed_url  = wp_parse_url( $upload_info['url'] );
    3036     $upload_host = isset( $parsed_url['host'] ) ? $parsed_url['host'] : '';
     3036    $upload_host = $parsed_url['host'] ?? '';
    30373037    $upload_port = isset( $parsed_url['port'] ) ? ':' . $parsed_url['port'] : '';
    30383038
Note: See TracChangeset for help on using the changeset viewer.