1
0
mirror of https://github.com/silverstripe/silverstripe-staticpublisher synced 2024-10-22 14:05:54 +02:00

Merge pull request from dhensby/patch-3

FIX Removing dependence on cache dir name
This commit is contained in:
☃ Stephen Shkardoon ☃ 2016-02-03 11:46:04 +13:00
commit 99e5162f23

View File

@ -114,7 +114,7 @@ class RebuildStaticCacheTask extends BuildTask
if (Config::inst()->get('FilesystemPublisher', 'domain_based_caching')) {
// Glob each dir, then glob each one of those
foreach (glob(BASE_PATH . '/cache/*', GLOB_ONLYDIR) as $cacheDir) {
foreach (glob($cacheBaseDir .'/*', GLOB_ONLYDIR) as $cacheDir) {
foreach (glob($cacheDir.'/*') as $cacheFile) {
$searchCacheFile = trim(str_replace($cacheBaseDir, '', $cacheFile), '\/');