summaryrefslogtreecommitdiffstats
path: root/lib/private/Template
diff options
context:
space:
mode:
authorJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2017-12-28 10:28:16 +0100
committerJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2017-12-30 05:55:45 +0100
commit88b72fd027e50c4f45d2a5eb47762dae67815593 (patch)
treeebe4d9dd1db49df0986fd961dc2fcb341927e89b /lib/private/Template
parentdc938628f7bacd16f88b2cf9cff3f46ec03fc929 (diff)
downloadnextcloud-server-88b72fd027e50c4f45d2a5eb47762dae67815593.tar.gz
nextcloud-server-88b72fd027e50c4f45d2a5eb47762dae67815593.zip
Fixup! getWebdir return
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Diffstat (limited to 'lib/private/Template')
-rw-r--r--lib/private/Template/SCSSCacher.php8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/private/Template/SCSSCacher.php b/lib/private/Template/SCSSCacher.php
index 0409071102d..8d1eda99ee0 100644
--- a/lib/private/Template/SCSSCacher.php
+++ b/lib/private/Template/SCSSCacher.php
@@ -317,12 +317,8 @@ class SCSSCacher {
* @return string the webDir
*/
private function getWebDir($path, $app) {
- // Detect if path is within server root
- if(strpos($path, $this->serverRoot) > -1) {
- return \OC::$WEBROOT.substr($path, strlen($this->serverRoot));
- }
- // Detect if path is within an app path
- if($appWebPath = \OC_App::getAppWebPath($app)) {
+ // Detect if path is within server root AND if path is within an app path
+ if ( strpos($path, $this->serverRoot) === -1 && $appWebPath = \OC_App::getAppWebPath($app) ) {
// Get the file path within the app directory
$appDirectoryPath = explode($app, $path)[1];
// Remove the webroot