Back to FileStorage class

Method remove

public bool
remove
(mixed $id, mixed $group)
Remove a cached data entry by ID and group
Parameters
  • string $id The cache data ID
  • string $group The cache data group
Returns
  • bool
Since
  • 1.7.0
Class: FileStorage
Project: Joomla

Method remove - Source code

/**
 * Remove a cached data entry by ID and group
 *
 * @param   string  $id     The cache data ID
 * @param   string  $group  The cache data group
 *
 * @return  boolean
 *
 * @since   1.7.0
 */
public function remove($id, $group)
{
    $path = $this->_getFilePath($id, $group);
    File::invalidateFileCache($path);
    if (!@unlink($path)) {
        return false;
    }
    return true;
}