[wp-trac] [WordPress Trac] #48003: Function wp_prepare_attachment_for_js() missing other sizes

WordPress Trac noreply at wordpress.org
Mon Oct 7 00:42:32 UTC 2019


#48003: Function wp_prepare_attachment_for_js() missing other sizes
--------------------------+------------------------------
 Reporter:  kkatusic      |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Media         |     Version:  5.2.3
 Severity:  minor         |  Resolution:
 Keywords:  needs-patch   |     Focuses:
--------------------------+------------------------------

Comment (by iCaleb):

 > Only difference between my code and your is that I don't use hook
 `image_size_names_choose`

 Right, that is the key here. Without "registering" the custom image size
 with a display name, it won't be shown on the attachment page in the
 dropdown, thus `wp_prepare_attachment_for_js()` doesn't need the data.

 You are sure this behavior was previously different? And if so, what
 version of WP were you on before you updated?

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/48003#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list