Make WordPress Core

Opened 4 years ago

Closed 4 years ago

#21518 closed defect (bug) (fixed)

Remove 'hwstring_small' property from attachment metadata

Reported by: koopersmith Owned by: nacin
Milestone: 3.5 Priority: low
Severity: minor Version: 3.4.1
Component: Media Keywords: dev-feedback has-patch
Focuses: Cc:


We don't appear to use the 'hwstring_small' meta key anywhere, and as a series of html attributes, it doesn't fit in with the rest of the attachment meta keys. Thoughts on removing (and/or deprecating) it?

Attachments (2)

21518.patch (2.9 KB) - added by SergeyBiryukov 4 years ago.
21518.2.patch (1.3 KB) - added by SergeyBiryukov 4 years ago.

Download all attachments as: .zip

Change History (7)

#1 @nacin
4 years ago

I'm fine with it vanishing. At worst, someone's image is no longer properly bound. Looks like it may not have been properly bound, anyway — it is based on an image downsize of 128 x 96, rather than any options.

Would be good to track down where it entered core and why. Sounds like it may be related to the old wp_get_attachment_thumb_file() and friends, before we had intermediate sizes.

#2 @SergeyBiryukov
4 years ago

  • Keywords has-patch added

Introduced in [2921], unused since [2958].

The patch also deprecates get_udims() (unused since [6309]), which is essentially a copy of wp_shrink_dimensions(), already deprecated in [12823]:

#3 @nacin
4 years ago

  • Owner set to nacin
  • Resolution set to fixed
  • Status changed from new to closed

In [21808]:

Remove 'hwstring_small' from attachment metadata and deprecate get_udims(). props SergeyBiryukov. fixes #21518.

#4 @SergeyBiryukov
4 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

21518.2.patch corrects @return values, which are reversed:

Also adds @see/@deprecated for consistency with other functions.

#5 @nacin
4 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In [21835]:

Correct return values for two deprecated media admin functions. props SergeyBiryukov. fixes #21518.

Note: See TracTickets for help on using tickets.