summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing/api
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@owncloud.com>2016-02-08 10:11:22 +0100
committerRoeland Jago Douma <rullzer@owncloud.com>2016-02-08 10:11:22 +0100
commitca32778975323e743f0a0c7c548d44e283eb6813 (patch)
tree8bb1a7a442d867b86da27bf89604ba047bc66753 /apps/files_sharing/api
parent4130639a7ede41e7178eb4ce1d4ba328a697f722 (diff)
downloadnextcloud-server-ca32778975323e743f0a0c7c548d44e283eb6813.tar.gz
nextcloud-server-ca32778975323e743f0a0c7c548d44e283eb6813.zip
Even single shares are returned as array
When fetching a single share using ../shares/<ID> we should still return an array of shares. Fixes #22189
Diffstat (limited to 'apps/files_sharing/api')
-rw-r--r--apps/files_sharing/api/share20ocs.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_sharing/api/share20ocs.php b/apps/files_sharing/api/share20ocs.php
index d7c5d004d9c..c03243d1d41 100644
--- a/apps/files_sharing/api/share20ocs.php
+++ b/apps/files_sharing/api/share20ocs.php
@@ -170,7 +170,7 @@ class Share20OCS {
if ($this->canAccessShare($share)) {
$share = $this->formatShare($share);
- return new \OC_OCS_Result($share);
+ return new \OC_OCS_Result([$share]);
} else {
return new \OC_OCS_Result(null, 404, 'wrong share ID, share doesn\'t exist.');
}