@@ -744,6 +744,7 @@ public function getShares(
744
744
* @param string $publicUpload
745
745
* @param string $expireDate
746
746
* @param string $note
747
+ * @param string $label
747
748
* @return DataResponse
748
749
* @throws LockedException
749
750
* @throws NotFoundException
@@ -758,7 +759,8 @@ public function updateShare(
758
759
string $ sendPasswordByTalk = null ,
759
760
string $ publicUpload = null ,
760
761
string $ expireDate = null ,
761
- string $ note = null
762
+ string $ note = null ,
763
+ string $ label = null
762
764
): DataResponse {
763
765
try {
764
766
$ share = $ this ->getShareById ($ id );
@@ -772,7 +774,14 @@ public function updateShare(
772
774
throw new OCSNotFoundException ($ this ->l ->t ('Wrong share ID, share doesn \'t exist ' ));
773
775
}
774
776
775
- if ($ permissions === null && $ password === null && $ sendPasswordByTalk === null && $ publicUpload === null && $ expireDate === null && $ note === null ) {
777
+ if ($ permissions === null &&
778
+ $ password === null &&
779
+ $ sendPasswordByTalk === null &&
780
+ $ publicUpload === null &&
781
+ $ expireDate === null &&
782
+ $ note === null &&
783
+ $ label === null
784
+ ) {
776
785
throw new OCSBadRequestException ($ this ->l ->t ('Wrong or no update parameter given ' ));
777
786
}
778
787
@@ -849,6 +858,10 @@ public function updateShare(
849
858
$ share ->setPassword ($ password );
850
859
}
851
860
861
+ if ($ label !== null ) {
862
+ $ share ->setLabel ($ label );
863
+ }
864
+
852
865
} else {
853
866
if ($ permissions !== null ) {
854
867
$ permissions = (int )$ permissions ;
0 commit comments