Docs: Move the canonical DocBlock for handle_bulk_actions-{$screen} action to wp-admin/edit.php.

* Document accepted values for the `$items` parameter.
* Use interpolated syntax for the filter name.

Props dilipbheda, johnbillion, SergeyBiryukov.
Fixes #48857.

git-svn-id: https://develop.svn.wordpress.org/trunk@46811 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov
2019-12-03 13:56:25 +00:00
parent 9440ad966b
commit 972ca00d2d
7 changed files with 43 additions and 30 deletions

View File

@@ -456,11 +456,12 @@ switch ( $wp_list_table->current_action() ) {
}
if ( $wp_list_table->current_action() && ! empty( $_REQUEST['users'] ) ) {
$userids = $_REQUEST['users'];
$screen = get_current_screen()->id;
$sendback = wp_get_referer();
$userids = $_REQUEST['users'];
/** This action is documented in wp-admin/edit-comments.php */
$sendback = apply_filters( 'handle_bulk_actions-' . get_current_screen()->id, $sendback, $wp_list_table->current_action(), $userids ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores
/** This action is documented in wp-admin/edit.php */
$sendback = apply_filters( "handle_bulk_actions-{$screen}", $sendback, $wp_list_table->current_action(), $userids ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores
wp_safe_redirect( $sendback );
exit;