Media: Ensure that post_id variable is initiated ahead of usage.
This prevents warnings when using custom bulk actions in the media library. Props gitlost, achbed, Boniu91, wpgurudev, hellofromTonya. Fixes #39589. Built from https://develop.svn.wordpress.org/trunk@51111 git-svn-id: http://core.svn.wordpress.org/trunk@50720 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
8ace500967
commit
2d6e474c85
|
@ -119,6 +119,7 @@ $doaction = $wp_list_table->current_action();
|
|||
|
||||
if ( $doaction ) {
|
||||
check_admin_referer( 'bulk-media' );
|
||||
$post_ids = array();
|
||||
|
||||
if ( 'delete_all' === $doaction ) {
|
||||
$post_ids = $wpdb->get_col( "SELECT ID FROM $wpdb->posts WHERE post_type='attachment' AND post_status = 'trash'" );
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.8-alpha-51110';
|
||||
$wp_version = '5.8-alpha-51111';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue