diff options
Diffstat (limited to 'lib/private/Template/JSResourceLocator.php')
-rw-r--r-- | lib/private/Template/JSResourceLocator.php | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/private/Template/JSResourceLocator.php b/lib/private/Template/JSResourceLocator.php index b283f0b610f..68a83fa4b73 100644 --- a/lib/private/Template/JSResourceLocator.php +++ b/lib/private/Template/JSResourceLocator.php @@ -60,8 +60,13 @@ class JSResourceLocator extends ResourceLocator { $found += $this->appendScriptIfExist($this->serverroot, $theme_dir.'core/'.$script); $found += $this->appendScriptIfExist($this->serverroot, $script); $found += $this->appendScriptIfExist($this->serverroot, $theme_dir.$script); - $found += $this->appendScriptIfExist($this->serverroot, 'apps/'.$script); - $found += $this->appendScriptIfExist($this->serverroot, $theme_dir.'apps/'.$script); + + foreach (\OC::$APPSROOTS as $appRoot) { + $dirName = basename($appRoot['path']); + $rootPath = dirname($appRoot['path']); + $found += $this->appendScriptIfExist($rootPath, $dirName.'/'.$script); + $found += $this->appendScriptIfExist($this->serverroot, $theme_dir.$dirName.'/'.$script); + } if ($found) { return; |