From 271d8ca5bf98f73095a439963d028cbc62696861 Mon Sep 17 00:00:00 2001 From: Steve Clay Date: Tue, 29 Sep 2015 11:31:28 -0400 Subject: [PATCH] Don't assume all allowDir paths start with "//" --- lib/Minify/Source/Factory.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/Minify/Source/Factory.php b/lib/Minify/Source/Factory.php index 4f926ae..04c71c8 100644 --- a/lib/Minify/Source/Factory.php +++ b/lib/Minify/Source/Factory.php @@ -56,7 +56,9 @@ class Minify_Source_Factory { // resolve // in allowDirs $docRoot = $env->getDocRoot(); foreach ($this->options['allowDirs'] as $i => $dir) { - $this->options['allowDirs'][$i] = $docRoot . substr($dir, 1); + if (0 === strpos($dir, '//')) { + $this->options['allowDirs'][$i] = $docRoot . substr($dir, 1); + } } if ($this->options['fileChecker'] && !is_callable($this->options['fileChecker'])) {