summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJohannes Leuker <j.leuker@hosting.de>2020-12-08 15:12:04 +0100
committerJohannes Leuker <j.leuker@hosting.de>2021-01-12 10:38:39 +0100
commitac88bcbd5f03419e149dac2a080f8f206876547e (patch)
tree3448cc127bc4bdc55276d123ccaa96b3dcfe291e /lib
parent15924b8832fef063f78ba189b1f2d68049e36779 (diff)
downloadnextcloud-server-ac88bcbd5f03419e149dac2a080f8f206876547e.tar.gz
nextcloud-server-ac88bcbd5f03419e149dac2a080f8f206876547e.zip
Add 'allow Symlinks' as an option to config.php
Signed-off-by: Johannes Leuker <j.leuker@hosting.de>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Files/Storage/Local.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php
index 5d0ce596b11..81d1d083eb8 100644
--- a/lib/private/Files/Storage/Local.php
+++ b/lib/private/Files/Storage/Local.php
@@ -58,8 +58,6 @@ class Local extends \OC\Files\Storage\Common {
protected $dataDirLength;
- protected $allowSymlinks = false;
-
protected $realDataDir;
public function __construct($arguments) {
@@ -441,7 +439,8 @@ class Local extends \OC\Files\Storage\Common {
$fullPath = $this->datadir . $path;
$currentPath = $path;
- if ($this->allowSymlinks || $currentPath === '') {
+ $allowSymlinks = \OC::$server->getConfig()->getSystemValue('localstorage.allowsymlinks', false);
+ if ($allowSymlinks || $currentPath === '') {
return $fullPath;
}
$pathToResolve = $fullPath;