From 766537705879fe0a4b3c1a495cfbc03bf7c71416 Mon Sep 17 00:00:00 2001 From: Scott Taylor Date: Wed, 7 Oct 2015 02:44:59 +0000 Subject: [PATCH] Meta Boxes: add an action, `post_submitbox_minor_actions`. `post_submitbox_misc_actions` already exists. Pass `$post` to both for context - avoids having to check for a global post. Props jonathanbardo, chriscct7, DrewAPicture. Fixes #26267. git-svn-id: https://develop.svn.wordpress.org/trunk@34895 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/meta-boxes.php | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/wp-admin/includes/meta-boxes.php b/src/wp-admin/includes/meta-boxes.php index 8429b57935..ed477273ab 100644 --- a/src/wp-admin/includes/meta-boxes.php +++ b/src/wp-admin/includes/meta-boxes.php @@ -51,6 +51,16 @@ if ( 'publish' == $post->post_status ) { +
@@ -207,8 +217,11 @@ if ( $can_publish ) : // Contributors don't get to choose the date of publish ?> * Fires after the post time/date setting in the Publish meta box. * * @since 2.9.0 + * @since 4.4.0 Added the `$post` parameter. + * + * @param WP_Post $post WP_Post object for the current post. */ -do_action( 'post_submitbox_misc_actions' ); +do_action( 'post_submitbox_misc_actions', $post ); ?>