WordPress Snippets at WPcustoms

Disable updates for specific plugin

Prevent update notification for plugin. If you want to prevent a plugin to check for updates simply put this function into your functions.php file and update the “your-plugin-folder/plugin.php” with the name of the plugin you don`t want to update.


/**
 * Snippet Name: Disable updates for specific plugin
 * Snippet URL: http://www.wpcustoms.net/snippets/disable-updates-specific-plugin/
 */
 
function disable_plugin_updates( $value ) {
  if ( isset($value) && is_object($value) ) {
    if ( isset( $value->response['your-plugin-folder/plugin.php'] ) ) {
      unset( $value->response['your-plugin-folder/plugin.php'] );
    }
  }
  return $value;
}
add_filter( 'site_transient_update_plugins', 'disable_plugin_updates' );