Mecha CMS

Cache::expire()

Check if cache file already expired.

2.0.02.2.0Static

Cache::expire(string $id, string $for = '1 day');
Cache::expire(string $id, int $for = 86400);

Example:

if (Cache::expire('foo', '1 year')) {
    // Expired!
}