Make WordPress Core

Opened 6 years ago

Last modified 5 years ago

#45083 new enhancement

use `image_default_size` option in WP_Widget_Media_Image instead of hard-coded value

Reported by: toro_unit's profile Toro_Unit Owned by:
Milestone: Future Release Priority: normal
Severity: normal Version: 4.8
Component: Widgets Keywords: has-patch
Focuses: Cc:


default image size in WP_Widget_Media_Image is 'medium'.

Should be used get_option( 'image_default_size', 'medium' )

Attachments (2)

45083.patch (716 bytes) - added by Toro_Unit 6 years ago.
45083.diff (1.0 KB) - added by welcher 5 years ago.

Download all attachments as: .zip

Change History (3)

6 years ago

#1 @welcher
5 years ago

  • Milestone changed from Awaiting Review to Future Release
  • Summary changed from use `image_default_size` option in WP_Widget_Media_Image to use `image_default_size` option in WP_Widget_Media_Image instead of hard-coded value
  • Type changed from defect (bug) to enhancement

@Toro_Unit thanks for the ticket and the patch!

This looks good to me.

I am wondering if we may want to consider adding a filter the return of the get_option call. This will allow users to change the default value of this widget without affecting the default size of other media throughout the site.

Patch updated.

5 years ago

Note: See TracTickets for help on using tickets.