aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2013-07-05 09:58:41 +0200
committerThomas Müller <thomas.mueller@tmit.eu>2013-07-05 09:58:41 +0200
commit11172db55b5d180a9c16adb75360050985b9fe60 (patch)
tree51d8168d504666d9c655d3db1a771298b102f533
parent955646c4618110cd80c51f283b74848c9a013c41 (diff)
downloadnextcloud-server-11172db55b5d180a9c16adb75360050985b9fe60.tar.gz
nextcloud-server-11172db55b5d180a9c16adb75360050985b9fe60.zip
handle anonymous upload to reshared folder
-rw-r--r--apps/files/ajax/upload.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/files/ajax/upload.php b/apps/files/ajax/upload.php
index 8433716dec1..fd6aa981542 100644
--- a/apps/files/ajax/upload.php
+++ b/apps/files/ajax/upload.php
@@ -35,6 +35,11 @@ if (empty($_POST['dirToken'])) {
isset($_POST['subdir']) ? $_POST['subdir'] : ''
);
+ // handle reshare
+ if (!empty($linkItem['parent'])) {
+ $dir = '/Shared'.$dir;
+ }
+
if (!$dir || empty($dir) || $dir === false) {
OCP\JSON::error(array('data' => array_merge(array('message' => $l->t('Unable to set upload directory.')))));
die();