WP_CLI
FileCache::remove()
Remove file from cache
Method of the class: FileCache{}
No Hooks.
Return
true|false
.
Usage
$FileCache = new FileCache(); $FileCache->remove( $key );
- $key(string) (required)
- cache key
FileCache::remove() FileCache::remove code WP-CLI 2.8.0-alpha
public function remove( $key ) { if ( ! $this->enabled ) { return false; } $filename = $this->filename( $key ); if ( file_exists( $filename ) ) { return unlink( $filename ); } return false; }