Plugins: Display Auto-updates filters when the current view is "Must Use" or "Drop-in".

This changeset fixes a bug where the "Auto-updates Enabled/Disabled" filters were not showing when the current view is "Must Use" or "Drop-in".

Props NekoJonez, pbiron, costdev, audrasjb.
Fixes #54309.



Built from https://develop.svn.wordpress.org/trunk@55903


git-svn-id: http://core.svn.wordpress.org/trunk@55415 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
audrasjb 2023-06-10 05:30:22 +00:00
parent d9faf17705
commit 116d5d03c3
2 changed files with 4 additions and 5 deletions

View File

@ -61,8 +61,7 @@ class WP_Plugins_List_Table extends WP_List_Table {
$this->show_autoupdates = wp_is_auto_update_enabled_for_type( 'plugin' )
&& current_user_can( 'update_plugins' )
&& ( ! is_multisite() || $this->screen->in_admin( 'network' ) )
&& ! in_array( $status, array( 'mustuse', 'dropins' ), true );
&& ( ! is_multisite() || $this->screen->in_admin( 'network' ) );
}
/**
@ -463,7 +462,7 @@ class WP_Plugins_List_Table extends WP_List_Table {
'description' => __( 'Description' ),
);
if ( $this->show_autoupdates ) {
if ( $this->show_autoupdates && ! in_array( $status, array( 'mustuse', 'dropins' ), true ) ) {
$columns['auto-updates'] = __( 'Automatic Updates' );
}
@ -1154,7 +1153,7 @@ class WP_Plugins_List_Table extends WP_List_Table {
echo '</td>';
break;
case 'auto-updates':
if ( ! $this->show_autoupdates ) {
if ( ! $this->show_autoupdates || in_array( $status, array( 'mustuse', 'dropins' ), true ) ) {
break;
}

View File

@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.3-alpha-55902';
$wp_version = '6.3-alpha-55903';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.