diff options
Diffstat (limited to 'apps/files_sharing/ajax/setpermissions.php')
-rwxr-xr-x | apps/files_sharing/ajax/setpermissions.php | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/apps/files_sharing/ajax/setpermissions.php b/apps/files_sharing/ajax/setpermissions.php index 73f59d73db2..2f4c5da9788 100755 --- a/apps/files_sharing/ajax/setpermissions.php +++ b/apps/files_sharing/ajax/setpermissions.php @@ -1,13 +1,14 @@ <?php -//$RUNTIME_NOAPPS = true; +require_once(OC::$APPSROOT . '/apps/files_sharing/lib_share.php'); - OCP\JSON::checkAppEnabled('files_sharing'); -require_once(OC::$APPSROOT . '/apps/files_sharing/lib_share.php'); +OCP\JSON::checkLoggedIn(); -$source = "/".OCP\USER::getUser()."/files".$_GET['source']; -$uid_shared_with = $_GET['uid_shared_with']; -$permissions = $_GET['permissions']; +$source = '/'.OCP\USER::getUser().'/files'.$_POST['source']; +$uid_shared_with = $_POST['uid_shared_with']; +$permissions = $_POST['permissions']; OC_Share::setPermissions($source, $uid_shared_with, $permissions); +OCP\JSON::success(); + ?> |