diff --git a/bin/cache-clear b/bin/cache-clear index c8f53122..2ca84ce6 100755 --- a/bin/cache-clear +++ b/bin/cache-clear @@ -10,6 +10,7 @@ require __DIR__ . '/../lib/config.php'; $container = require __DIR__ . '/../lib/dependencies.php'; +/** @var CacheInterface $cache */ $cache = $container['cache']; $cache->clear(); diff --git a/bin/cache-prune b/bin/cache-prune index 755ed8d5..bb72c4ac 100755 --- a/bin/cache-prune +++ b/bin/cache-prune @@ -10,15 +10,15 @@ require __DIR__ . '/../lib/config.php'; $container = require __DIR__ . '/../lib/dependencies.php'; -/** @var CacheInterface $cache */ -$cache = $container['cache']; - if ( Configuration::getConfig('cache', 'type') === 'file' && !Configuration::getConfig('FileCache', 'enable_purge') ) { - // Override enable_purge for this execution + // Override enable_purge for this particular execution Configuration::setConfig('FileCache', 'enable_purge', true); } +/** @var CacheInterface $cache */ +$cache = $container['cache']; + $cache->prune();