Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2021-12-06 10:59:51 +0300
committerGitHub <noreply@github.com>2021-12-06 10:59:51 +0300
commit00549f78026108219ed77c4277cf6382a9a2101e (patch)
tree91db6593bb9009077450b1ddb15897781d837323 /apps/files_sharing/lib
parentf0e1621eed1ab30acd156ccaf9e513f29a7e3561 (diff)
parent5116bf146f3e21805d42997ca9b1f713474bfb6d (diff)
Merge pull request #30055 from nextcloud/enh/note-share-api
Diffstat (limited to 'apps/files_sharing/lib')
-rw-r--r--apps/files_sharing/lib/Controller/ShareAPIController.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/files_sharing/lib/Controller/ShareAPIController.php b/apps/files_sharing/lib/Controller/ShareAPIController.php
index c9853f1e12c..96b105aae49 100644
--- a/apps/files_sharing/lib/Controller/ShareAPIController.php
+++ b/apps/files_sharing/lib/Controller/ShareAPIController.php
@@ -449,6 +449,7 @@ class ShareAPIController extends OCSController {
string $password = '',
string $sendPasswordByTalk = null,
string $expireDate = '',
+ string $note = '',
string $label = ''
): DataResponse {
$share = $this->shareManager->newShare();
@@ -653,6 +654,10 @@ class ShareAPIController extends OCSController {
$share->setShareType($shareType);
$share->setSharedBy($this->currentUser);
+ if ($note !== '') {
+ $share->setNote($note);
+ }
+
try {
$share = $this->shareManager->createShare($share);
} catch (GenericShareException $e) {