From c65973e0f505c287468e204bcb461dfeafab4ee6 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 18 Aug 2020 20:36:42 +0000 Subject: [PATCH] Plugins: Avoid a PHP notice if the `update-supported` key in plugin data is not set. Props sanzeeb3. Fixes #51052. git-svn-id: https://develop.svn.wordpress.org/trunk@48820 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-plugins-list-table.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-admin/includes/class-wp-plugins-list-table.php b/src/wp-admin/includes/class-wp-plugins-list-table.php index 40223b6d47..e487e32cfb 100644 --- a/src/wp-admin/includes/class-wp-plugins-list-table.php +++ b/src/wp-admin/includes/class-wp-plugins-list-table.php @@ -1094,14 +1094,14 @@ class WP_Plugins_List_Table extends WP_List_Table { if ( isset( $plugin_data['auto-update-forced'] ) ) { if ( $plugin_data['auto-update-forced'] ) { - // Forced on + // Forced on. $text = __( 'Auto-updates enabled' ); } else { $text = __( 'Auto-updates disabled' ); } $action = 'unavailable'; $time_class = ' hidden'; - } elseif ( ! $plugin_data['update-supported'] ) { + } elseif ( empty( $plugin_data['update-supported'] ) ) { $text = ''; $action = 'unavailable'; $time_class = ' hidden';