Skip to content

Commit 46e5b14

Browse files
cleanup
1 parent 5b99bd8 commit 46e5b14

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

src/wp-admin/includes/image.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -511,7 +511,6 @@ function _wp_make_subsizes( $new_sizes, $file, $image_meta, $attachment_id, $mim
511511
$mime_type = $original_mime_type;
512512
}
513513

514-
515514
// Check if any of the new sizes already exist.
516515
if ( isset( $image_meta['sizes'] ) && is_array( $image_meta['sizes'] ) ) {
517516
foreach ( $image_meta['sizes'] as $size_name => $size_meta ) {

src/wp-includes/media.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ function add_image_size( $name, $width = 0, $height = 0, $crop = false, $output_
304304
'width' => absint( $width ),
305305
'height' => absint( $height ),
306306
'crop' => $crop,
307-
'output_mimes' => $output_mimes
307+
'output_mimes' => $output_mimes,
308308
);
309309
}
310310

@@ -321,9 +321,7 @@ function add_image_size( $name, $width = 0, $height = 0, $crop = false, $output_
321321
*/
322322
function image_size_supports_mime( $name, $mime_type ) {
323323
$sizes = wp_get_additional_image_sizes();
324-
error_log( 'image_size_supports_mime --- ' . json_encode( $sizes, JSON_PRETTY_PRINT));
325-
326-
return isset( $sizes[ $name ][ 'output_mimes' ] ) && $sizes[ $name ][ 'output_mimes' ];
324+
return isset( $sizes[ $name ]['output_mimes'] ) && $sizes[ $name ]['output_mimes'];
327325
}
328326

329327
/**
@@ -918,7 +916,7 @@ function wp_get_registered_image_subsizes() {
918916
$all_sizes = array();
919917

920918
foreach ( get_intermediate_image_sizes() as $size_name ) {
921-
$default_sizes = array( 'thumbnail', 'medium', 'medium_large', 'large' );
919+
$default_sizes = array( 'thumbnail', 'medium', 'medium_large', 'large' );
922920
foreach ( get_intermediate_image_sizes() as $size_name ) {
923921
$size_data = array(
924922
'width' => 0,

0 commit comments

Comments
 (0)