Coding Standards: Consistently use do_action_deprecated() and apply_filters_deprecated() for deprecated hooks.

Props jrf.
See #48255.

git-svn-id: https://develop.svn.wordpress.org/trunk@46684 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov
2019-11-09 12:57:27 +00:00
parent 243d1a2e38
commit ae2ebb8b18
14 changed files with 57 additions and 37 deletions

View File

@@ -6332,7 +6332,7 @@ function get_posts_by_author_sql( $post_type, $full = true, $post_author = null,
*
* @param string $cap Capability.
*/
$cap = apply_filters( 'pub_priv_sql_capability', '' );
$cap = apply_filters_deprecated( 'pub_priv_sql_capability', array( '' ), '3.2.0' );
if ( ! $cap ) {
$cap = current_user_can( $post_type_obj->cap->read_private_posts );
}
@@ -6741,7 +6741,7 @@ function _transition_post_status( $new_status, $old_status, $post ) {
*
* @param int $post_id Post ID.
*/
do_action( 'private_to_published', $post->ID );
do_action_deprecated( 'private_to_published', array( $post->ID ), '2.3.0', 'private_to_publish' );
}
// If published posts changed clear the lastpostmodified cache.