diff options
author | Björn Schießle <schiessle@owncloud.com> | 2016-05-13 20:36:42 +0200 |
---|---|---|
committer | Björn Schießle <schiessle@owncloud.com> | 2016-05-20 21:15:15 +0200 |
commit | 2dc26aada7977ad1416d6ac9797355807ab3d190 (patch) | |
tree | 3e1736f946f881d631857a190b76ac4a969dd73c /apps/federatedfilesharing/lib/Notifications.php | |
parent | 7b25839bd51b3b6cd920209c254f014c03437113 (diff) | |
download | nextcloud-server-2dc26aada7977ad1416d6ac9797355807ab3d190.tar.gz nextcloud-server-2dc26aada7977ad1416d6ac9797355807ab3d190.zip |
update share permissions
Diffstat (limited to 'apps/federatedfilesharing/lib/Notifications.php')
-rw-r--r-- | apps/federatedfilesharing/lib/Notifications.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/federatedfilesharing/lib/Notifications.php b/apps/federatedfilesharing/lib/Notifications.php index c65da212aad..ef59d0a5fdc 100644 --- a/apps/federatedfilesharing/lib/Notifications.php +++ b/apps/federatedfilesharing/lib/Notifications.php @@ -183,7 +183,7 @@ class Notifications { * @return bool */ public function sendPermissionChange($remote, $remoteId, $token, $permissions) { - $this->sendUpdateToRemote($remote, $remoteId, $token, ['permissions' => $permissions]); + $this->sendUpdateToRemote($remote, $remoteId, $token, 'permissions', ['permissions' => $permissions]); } /** @@ -222,6 +222,10 @@ class Notifications { public function sendUpdateToRemote($remote, $remoteId, $token, $action, $data = [], $try = 0) { $fields = array('token' => $token); + foreach ($data as $key => $value) { + $fields[$key] = $value; + } + $url = $this->addressHandler->removeProtocolFromUrl($remote); $result = $this->tryHttpPostToShareEndpoint(rtrim($url, '/'), '/' . $remoteId . '/' . $action, $fields); $status = json_decode($result['result'], true); |