diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/Storage/Wrapper/PermissionsMask.php | 8 | ||||
-rw-r--r-- | lib/private/legacy/template.php | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/lib/private/Files/Storage/Wrapper/PermissionsMask.php b/lib/private/Files/Storage/Wrapper/PermissionsMask.php index 39375602c34..7bcb1087fef 100644 --- a/lib/private/Files/Storage/Wrapper/PermissionsMask.php +++ b/lib/private/Files/Storage/Wrapper/PermissionsMask.php @@ -78,6 +78,14 @@ class PermissionsMask extends Wrapper { } public function rename($path1, $path2) { + $p = strpos($path1, $path2); + if ($p === 0) { + $part = substr($path1, strlen($path2)); + //This is a rename of the transfer file to the original file + if (strpos($part, '.ocTransferId') === 0) { + return $this->checkMask(Constants::PERMISSION_CREATE) and parent::rename($path1, $path2); + } + } return $this->checkMask(Constants::PERMISSION_UPDATE) and parent::rename($path1, $path2); } diff --git a/lib/private/legacy/template.php b/lib/private/legacy/template.php index 7520ffd44ed..7c0b58db0c0 100644 --- a/lib/private/legacy/template.php +++ b/lib/private/legacy/template.php @@ -139,6 +139,7 @@ class OC_Template extends \OC\Template\Base { OC_Util::addScript("oc-requesttoken", null, true); OC_Util::addScript('search', 'search', true); OC_Util::addScript("config", null, true); + OC_Util::addScript("public/appconfig", null, true); OC_Util::addScript("eventsource", null, true); OC_Util::addScript("octemplate", null, true); OC_Util::addTranslations("core", null, true); |