Skip to content
This repository has been archived by the owner on May 29, 2020. It is now read-only.

Commit

Permalink
Merge pull request #47 from audrasjb/fix/issue-45
Browse files Browse the repository at this point in the history
Prevent "PHP Notice: Undefined index: plugin_status" when adding the autoupdates_column
  • Loading branch information
pbiron authored Mar 10, 2020
2 parents 6975951 + 92770d3 commit 5e37c25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wp-autoupdates.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ function wp_autoupdates_selected_plugins( $update, $item ) {
* Add autoupdate column to plugins screen.
*/
function wp_autoupdates_add_plugins_autoupdates_column( $columns ) {
if ( 'mustuse' !== $_GET['plugin_status'] && 'dropins' !== $_GET['plugin_status'] ) {
if ( ! isset( $_GET['plugin_status'] ) || ( 'mustuse' !== $_GET['plugin_status'] && 'dropins' !== $_GET['plugin_status'] ) ) {
$columns['autoupdates_column'] = __( 'Automatic updates', 'wp-autoupdates' );
}
return $columns;
Expand Down

0 comments on commit 5e37c25

Please sign in to comment.