Make WordPress Core

Changeset 48518


Ignore:
Timestamp:
07/20/2020 09:02:13 PM (6 years ago)
Author:
azaozz
Message:

REST API, Media: Fix/improve the inline docs and name of the new wp_edited_image_metadata filter.

Props desrosj, azaozz.

See #44405.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php

    r48510 r48518  
    608608
    609609                /**
    610                  * Filters the updated attachment meta data.
     610                 * Filters the meta data for the new image created by editing an existing image.
    611611                 *
    612612                 * @since 5.5.0
    613613                 *
    614                  * @param array $data              Array of updated attachment meta data.
    615                  * @param int   $new_attachment_id Attachment post ID.
    616                  * @param int   $attachment_id     Original Attachment post ID.
     614                 * @param array $new_image_meta    Meta data for the new image.
     615                 * @param int   $new_attachment_id Attachment post ID for the new image.
     616                 * @param int   $attachment_id     Attachment post ID for the edited (parent) image.
    617617                 */
    618                 $new_image_meta = apply_filters( 'wp_edited_attachment_metadata', $new_image_meta, $new_attachment_id, $attachment_id );
     618                $new_image_meta = apply_filters( 'wp_edited_image_metadata', $new_image_meta, $new_attachment_id, $attachment_id );
    619619
    620620                wp_update_attachment_metadata( $new_attachment_id, $new_image_meta );
Note: See TracChangeset for help on using the changeset viewer.