From ea4bc78cb6d907ff5c90ca7033acdc4b92e84f3c Mon Sep 17 00:00:00 2001 From: Gevorg Ablabutyan Date: Thu, 15 Jun 2017 11:53:00 -0700 Subject: [PATCH] Added directory exclusion --- src/Vinelab/Cdn/Finder.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Vinelab/Cdn/Finder.php b/src/Vinelab/Cdn/Finder.php index 546a678..68b12c3 100755 --- a/src/Vinelab/Cdn/Finder.php +++ b/src/Vinelab/Cdn/Finder.php @@ -107,6 +107,11 @@ private function excludeThis(AssetInterface $asset_holder) $this->notName($name); } + // exclude directories + foreach ($asset_holder->getExcludedDirectories() as $name) { + $this->notName($name.'/**/*'); + } + // exclude files (if exist) with this extensions $excluded_extensions = $asset_holder->getExcludedExtensions(); if (!empty($excluded_extensions)) {