summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2017-12-14 08:51:53 +0100
committerJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2017-12-14 11:11:54 +0100
commitf2d5927ea3bbd2ccd7152bc3638b25b5e577f94e (patch)
tree9f08472af3b42f7455bae8f12d03d2cd0a98adaa
parent1f108970c45c2269e68094ced1e9f13f1ac0f863 (diff)
downloadnextcloud-server-f2d5927ea3bbd2ccd7152bc3638b25b5e577f94e.tar.gz
nextcloud-server-f2d5927ea3bbd2ccd7152bc3638b25b5e577f94e.zip
Reduce length of md5 in scss caching
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
-rw-r--r--lib/private/Template/SCSSCacher.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/Template/SCSSCacher.php b/lib/private/Template/SCSSCacher.php
index cd69b8b63c3..8f6cb85a120 100644
--- a/lib/private/Template/SCSSCacher.php
+++ b/lib/private/Template/SCSSCacher.php
@@ -285,7 +285,7 @@ class SCSSCacher {
$re = '/url\([\'"]([\.\w?=\/-]*)[\'"]\)/x';
// OC\Route\Router:75
if(($this->config->getSystemValue('htaccess.IgnoreFrontController', false) === true || getenv('front_controller_active') === 'true')) {
- $subst = 'url(\'../../'.$webDir.'/$1\')';
+ $subst = 'url(\'../../'.$webDir.'/$1\')';
} else {
$subst = 'url(\'../../../'.$webDir.'/$1\')';
}
@@ -313,6 +313,6 @@ class SCSSCacher {
*/
private function prependBaseurlPrefix($cssFile) {
$frontendController = ($this->config->getSystemValue('htaccess.IgnoreFrontController', false) === true || getenv('front_controller_active') === 'true');
- return md5($this->urlGenerator->getBaseUrl() . $frontendController) . '-' . $cssFile;
+ return substr(md5($this->urlGenerator->getBaseUrl() . $frontendController), 0, 8) . '-' . $cssFile;
}
}