Make WordPress Core

Ticket #34706: 34706.diff

File 34706.diff, 684 bytes (added by Mte90, 7 years ago)

added the filter

  • src/wp-includes/post.php

    diff --git src/wp-includes/post.php src/wp-includes/post.php
    index 52fb11909c..a0b2b90c65 100644
    function wp_insert_post( $postarr, $wp_error = false ) { 
    36943694        }
    36953695
    36963696        if ( $update ) {
     3697 
     3698                /**
     3699                 * Fires once an existing post has been updated.
     3700                 *
     3701                 * The dynamic portion of the hook name, `$post->post_type`, refers to
     3702                 * the post type slug.
     3703                 *
     3704                 * @since 4.9.5
     3705                 *
     3706                 * @param int     $post_ID Post ID.
     3707                 * @param WP_Post $post    Post object.
     3708                */
     3709                do_action( "edit_post_{$post->post_type}", $post_ID, $post );
     3710   
    36973711                /**
    36983712                 * Fires once an existing post has been updated.
    36993713                 *