Make WordPress Core

Changeset 59018


Ignore:
Timestamp:
09/13/2024 05:21:45 AM (2 months ago)
Author:
peterwilsoncc
Message:

Upgrade/Install: Indicate HEIC support when checking upgrades.

Adds tracking of HEIC image type support alongside WebP and AVID image types when requesting upgrade from WordPress.org

Props adamsilverstein, swissspidy, dd32, mukesh27.
Fixes #61981.

File:
1 edited

Legend:

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

    r58906 r59018  
    116116        $gd_info = array_filter( $gd_info );
    117117
    118         // Add data for GD WebP and AVIF support.
     118        // Add data for GD WebP, AVIF and HEIC support.
    119119        $query['image_support']['gd'] = array_keys(
    120120            array_filter(
     
    122122                    'webp' => isset( $gd_info['WebP Support'] ),
    123123                    'avif' => isset( $gd_info['AVIF Support'] ),
     124                    'heic' => isset( $gd_info['HEIC Support'] ),
    124125                )
    125126            )
     
    128129
    129130    if ( class_exists( 'Imagick' ) ) {
    130         // Add data for Imagick WebP and AVIF support.
     131        // Add data for Imagick WebP, AVIF and HEIC support.
    131132        $query['image_support']['imagick'] = array_keys(
    132133            array_filter(
     
    134135                    'webp' => ! empty( Imagick::queryFormats( 'WEBP' ) ),
    135136                    'avif' => ! empty( Imagick::queryFormats( 'AVIF' ) ),
     137                    'heic' => ! empty( Imagick::queryFormats( 'HEIC' ) ),
    136138                )
    137139            )
Note: See TracChangeset for help on using the changeset viewer.