tractorcow / silverstripe-dynamiccache

Simple on the fly caching of dynamic content for Silverstripe
39 stars 27 forks source link

use standard code for flush #72

Closed sunnysideup closed 6 years ago

sunnysideup commented 6 years ago

Re: https://github.com/tractorcow/silverstripe-dynamiccache/blob/master/code/DynamicCacheControllerExtension.php#L36

Why not make one of the classes implement flushable and then add the following static method:

public static function flush()
{
    DynamicCache::inst()->clear();
}
tractorcow commented 6 years ago

Ok sounds fair. :)