Skip to content

Instantly share code, notes, and snippets.

@alordiel
Created August 14, 2019 06:38
Show Gist options
  • Save alordiel/69d3545b5e1289fa5f082f95282445c5 to your computer and use it in GitHub Desktop.
Save alordiel/69d3545b5e1289fa5f082f95282445c5 to your computer and use it in GitHub Desktop.
Disable autoupdate and updates for paid plugins
<?php
define( 'automatic_updater_disabled', true );
define( 'wp_auto_update_core', false );
add_filter('site_transient_update_plugins', 'remove_update_notification');
function remove_update_notification($value)
{
unset($value->response['memberpress/memberpress.php']);
unset($value->response['wp-migrate-db-pro/wp-migrate-db-pro.php']);
unset($value->response['memberpress-mailchimp-tags/main.php']);
unset($value->response['paypal-ipn/paypal-ipn-for-wordpress.php']);
unset($value->response['admin-menu-editor-pro/menu-editor.php']);
return $value;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment