WordPress.org

Make WordPress Core

Ticket #46228: 46228.diff

File 46228.diff, 681 bytes (added by mukesh27, 3 years ago)

Patch.

  • wp-includes/post.php

    diff --git a/wp-includes/post.php b/wp-includes/post.php
    index e6ca1f2..626a227 100644
    a b function wp_insert_post( $postarr, $wp_error = false ) { 
    37093709                 *
    37103710                 * @param array $data    An array of slashed post data.
    37113711                 * @param array $postarr An array of sanitized, but otherwise unmodified post data.
     3712                 * @param bool  $update  Whether this is an existing post being updated or not.
    37123713                 */
    3713                 $data = apply_filters( 'wp_insert_post_data', $data, $postarr );
     3714                $data = apply_filters( 'wp_insert_post_data', $data, $postarr, $update );
    37143715        }
    37153716        $data  = wp_unslash( $data );
    37163717        $where = array( 'ID' => $post_ID );