wp_clean_plugins_cache() – Clears the Plugins cache used by get_plugins() and by default, the Plugin Update cache.

You appear to be a bot. Output may be restricted

Description

Clears the plugins cache used by get_plugins() and by default, the plugin updates cache.

Usage

wp_clean_plugins_cache( $clear_update_cache );

Parameters

$clear_update_cache
( bool ) optional default: 1 – Whether to clear the plugin updates cache. Default true.

Returns

void

Source

File name: wordpress/wp-admin/includes/plugin.php
Lines:

1 to 6 of 6
function wp_clean_plugins_cache( $clear_update_cache = true ) {
  if ( $clear_update_cache ) {
    delete_site_transient( 'update_plugins' );
  }
  wp_cache_delete( 'plugins', 'plugins' );
}
 

 View on GitHub View on Trac