Ticket #51038: 51038.diff
File 51038.diff, 695 bytes (added by , 4 years ago) |
---|
-
src/wp-includes/class-wp-image-editor-gd.php
307 307 * @return bool|WP_Error 308 308 */ 309 309 public function crop( $src_x, $src_y, $src_w, $src_h, $dst_w = null, $dst_h = null, $src_abs = false ) { 310 // If source height isn't specified, 311 // use height of the source file. 312 if( ! $src_h ) { 313 $size = getimagesize( $this->file ); 314 $src_h = $size[1]; 315 } 316 310 317 // If destination width/height isn't specified, 311 318 // use same as width/height from source. 312 319 if ( ! $dst_w ) {