Make WordPress Core

Ticket #58392: 58392.diff

File 58392.diff, 1.4 KB (added by dhruvishah2203, 17 months ago)

diff file uploaded

  • src/wp-includes/post.php

    diff --git a/src/wp-includes/post.php b/src/wp-includes/post.php
    index fabd68edb2..94f95835d2 100644
    a b function wp_trash_post( $post_id = 0 ) { 
    35913591         * Fires before a post is sent to the Trash.
    35923592         *
    35933593         * @since 3.3.0
     3594         * @since 6.3.0 Added the `$post` parameter.
    35943595         *
    3595          * @param int $post_id Post ID.
     3596         * @param int $post_id     Post ID.
     3597         * @param WP_Post $post    Post object.
    35963598         */
    3597         do_action( 'wp_trash_post', $post_id );
     3599        do_action( 'wp_trash_post', $post_id, $post );
    35983600
    35993601        add_post_meta( $post_id, '_wp_trash_meta_status', $post->post_status );
    36003602        add_post_meta( $post_id, '_wp_trash_meta_time', time() );