Ticket #48214: 48214.patch
File 48214.patch, 1.3 KB (added by , 6 years ago) |
---|
-
src/wp-admin/includes/image.php
203 203 */ 204 204 function wp_create_image_subsizes( $file, $attachment_id ) { 205 205 $imagesize = @getimagesize( $file ); 206 $max_image_size = 2560; 206 207 207 208 if ( empty( $imagesize ) ) { 208 209 // File is not an image. … … 235 236 * 236 237 * @since 5.3.0 237 238 * 238 * @param array $imagesize Indexed array of the image width and height (in that order). 239 * @param string $file Full path to the uploaded image file. 240 * @param int $attachment_id Attachment post ID. 239 * @patam int $max_image_size Max image available size. 240 * @param array $imagesize Indexed array of the image width and height (in that order). 241 * @param string $file Full path to the uploaded image file. 242 * @param int $attachment_id Attachment post ID. 241 243 */ 242 $threshold = (int) apply_filters( 'big_image_size_threshold', 2560, $imagesize, $file, $attachment_id );244 $threshold = (int) apply_filters( 'big_image_size_threshold', $max_image_size, $imagesize, $file, $attachment_id ); 243 245 244 246 // If the original image's dimensions are over the threshold, scale the image 245 247 // and use it as the "full" size.