From 4305bbabd5f22501fb523bfa1f56e1fdaf53de44 Mon Sep 17 00:00:00 2001 From: Andy Miller Date: Thu, 30 Apr 2015 18:05:30 -0600 Subject: [PATCH] fix for theme name same as base_url and asset pipeline --- system/src/Grav/Common/Assets.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/system/src/Grav/Common/Assets.php b/system/src/Grav/Common/Assets.php index 3b232f457..a2a741239 100644 --- a/system/src/Grav/Common/Assets.php +++ b/system/src/Grav/Common/Assets.php @@ -825,7 +825,7 @@ class Assets } else { // Fix to remove relative dir if grav is in one if (($this->base_url != '/') && (strpos($this->base_url, $link) == 0)) { - $relative_path = str_replace($this->base_url, '/', $link); + $relative_path = ltrim(preg_replace($this->base_url, '/', $link, 1), '/'); } $relative_dir = dirname($relative_path);