summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@owncloud.com>2015-07-07 11:08:21 +0200
committerJoas Schilling <nickvergessen@owncloud.com>2015-07-15 10:12:50 +0200
commit8f2ce01553e6e8c9e43863dd4f993fca10e88d24 (patch)
tree15305302e44e173a5e8c2c203f001e792fbb5523 /lib
parent3ade5f51119bc412324e656032330e277d0a00a9 (diff)
downloadnextcloud-server-8f2ce01553e6e8c9e43863dd4f993fca10e88d24.tar.gz
nextcloud-server-8f2ce01553e6e8c9e43863dd4f993fca10e88d24.zip
Make sure the owner always has the right path
Diffstat (limited to 'lib')
-rw-r--r--lib/private/share/share.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/private/share/share.php b/lib/private/share/share.php
index 2dc83bdcc45..2a9fa44f78d 100644
--- a/lib/private/share/share.php
+++ b/lib/private/share/share.php
@@ -253,9 +253,6 @@ class Share extends Constants {
// Include owner in list of users, if requested
if ($includeOwner) {
$shares[] = $ownerUser;
- if ($returnUserPaths) {
- $sharePaths[$ownerUser] = $path;
- }
}
if ($returnUserPaths) {
@@ -283,6 +280,12 @@ class Share extends Constants {
}
}
+ if ($includeOwner) {
+ $sharePaths[$ownerUser] = $path;
+ } else {
+ unset($sharePaths[$ownerUser]);
+ }
+
return $sharePaths;
}