Plugin Updates
This commit is contained in:
@@ -390,6 +390,12 @@ function wp_stream_image( $image, $mime_type, $attachment_id ) {
|
||||
return imagewebp( $image, null, 90 );
|
||||
}
|
||||
return false;
|
||||
case 'image/avif':
|
||||
if ( function_exists( 'imageavif' ) ) {
|
||||
header( 'Content-Type: image/avif' );
|
||||
return imageavif( $image, null, 90 );
|
||||
}
|
||||
return false;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
@@ -494,6 +500,11 @@ function wp_save_image_file( $filename, $image, $mime_type, $post_id ) {
|
||||
return imagewebp( $image, $filename );
|
||||
}
|
||||
return false;
|
||||
case 'image/avif':
|
||||
if ( function_exists( 'imageavif' ) ) {
|
||||
return imageavif( $image, $filename );
|
||||
}
|
||||
return false;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user