[wp-trac] [WordPress Trac] #48472: The "wp_generate_attachment_metadata" filter is not fired when the initial upload request fails but the upload was completed successfully by retrying to create image sub-sizes

WordPress Trac noreply at wordpress.org
Wed Oct 30 21:08:44 UTC 2019


#48472: The "wp_generate_attachment_metadata" filter is not fired when the initial
upload request fails but the upload was completed successfully by retrying
to create image sub-sizes
-------------------------------------------------+---------------------
 Reporter:  azaozz                               |       Owner:  azaozz
     Type:  defect (bug)                         |      Status:  closed
 Priority:  normal                               |   Milestone:  5.3
Component:  Upload                               |     Version:  trunk
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  has-patch needs-testing 2nd-opinion  |     Focuses:
-------------------------------------------------+---------------------
Changes (by azaozz):

 * owner:  (none) => azaozz
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"46621" 46621]:
 {{{
 #!CommitTicketReference repository="" revision="46621"
 Upload:
 - Run the `wp_generate_attachment_metadata` filter at the end in
 `wp_update_image_subsizes()` when new metadata was generated and
 additional image sub-sizes were created.
 - Add another arg in the `wp_generate_attachment_metadata` filter for
 additional context.
 - Fix inline docs and ensure the new image meta is always saved before
 starting post-processing.

 Fixes #48472 for trunk.
 }}}

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


More information about the wp-trac mailing list