wphooks.info - untrash_post

untrash_post

(trunk - 5.0-alpha-43293)

The hook occurs in the following file:

wp-includes/post.php:
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
		return $check;
	}

	/**
	 * Fires before a post is restored from the trash.
	 *
	 * @since 2.9.0
	 *
	 * @param int $post_id Post ID.
	 */
	do_action( 'untrash_post', $post_id );

	$post_status = get_post_meta( $post_id, '_wp_trash_meta_status', true );

	delete_post_meta( $post_id, '_wp_trash_meta_status' );
	delete_post_meta( $post_id, '_wp_trash_meta_time' );

	wp_update_post(
		array(
			'ID'          => $post_id,