handle anonymous upload to reshared folder

This commit is contained in:
Thomas Müller 2013-07-05 09:58:41 +02:00
parent 955646c461
commit 11172db55b
1 changed files with 5 additions and 0 deletions

View File

@ -35,6 +35,11 @@ if (empty($_POST['dirToken'])) {
isset($_POST['subdir']) ? $_POST['subdir'] : '' isset($_POST['subdir']) ? $_POST['subdir'] : ''
); );
// handle reshare
if (!empty($linkItem['parent'])) {
$dir = '/Shared'.$dir;
}
if (!$dir || empty($dir) || $dir === false) { if (!$dir || empty($dir) || $dir === false) {
OCP\JSON::error(array('data' => array_merge(array('message' => $l->t('Unable to set upload directory.'))))); OCP\JSON::error(array('data' => array_merge(array('message' => $l->t('Unable to set upload directory.')))));
die(); die();