diff --git a/plugins/webp-uploads/helper.php b/plugins/webp-uploads/helper.php index 7f1d6aae27..7a49b402dc 100644 --- a/plugins/webp-uploads/helper.php +++ b/plugins/webp-uploads/helper.php @@ -373,7 +373,7 @@ function webp_uploads_mime_type_supported( string $mime_type ): bool { // In certain server environments Image editors can report a false positive for AVIF support. if ( 'image/avif' === $mime_type ) { $editor = _wp_image_editor_choose( array( 'mime_type' => 'image/avif' ) ); - if ( 'WP_Image_Editor_GD' === $editor ) { + if ( is_a( $editor, WP_Image_Editor_GD::class, true ) ) { return function_exists( 'imageavif' ); } if ( 'WP_Image_Editor_Imagick' === $editor ) {